On 2012-03-18, at 3:04 PM, Dileepa Jayakody wrote:
> Hi Devs,
>
> I have a requirement of categorising IUs in an existing P2 Repo so that when
> the available features of the repo are queried, they are shown in groups
> under categories (like the 'Grouped by' feature in Eclipse). I came across
> the concept of category.xml to explicitly define IUs under categories.
> My question is how can I retrieve this category metadata when I query the
> available IUs from the repo?
> Can I use IRepository.getProperties() method to read the category metadata
> from the category.xml in the p2 repo?
> Or do I have to run 'Category Publisher' application to encode the category
> data into content.xml of the p2 repo; is there any other alternative method
> to categorise IUs in an existing repo?
The category.xml is only an authoring format. In the end, the
categories are represented by IUs (InstallableUnit) that are part of the
metadata repository (content.xml). Theses IUs are generated by the 'Category
Publisher'. Like any IU those can be access by querying the repository. The
query can be created using the following: QueryUtil#createIUCategoryQuery.
HTH
Pascal
=-=-=
Consulting, training, bug fixing - pascal (at) rapicault.net
>
> Thanks,
> Dileepa
> _______________________________________________
> p2-dev mailing list
> [email protected]
> https://dev.eclipse.org/mailman/listinfo/p2-dev
_______________________________________________
p2-dev mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/p2-dev