KNOWNID(PRODUCT_URL_TYPE, "product:url:type"),
KNOWNID(PRODUCT_FLAGS, "product:flags"),
KNOWNID(PRODUCT_PRODUCTLINE, "product:productline"),
+/* this has to be obsoleted */
KNOWNID(PRODUCT_UPDATEREPOKEY, "product:updaterepokey"),
KNOWNID(PRODUCT_REGISTER_TARGET, "product:regtarget"),
KNOWNID(PRODUCT_REGISTER_RELEASE, "product:regrelease"),
/* hint when the metadata could be outdated
w/respect to generated timestamp */
KNOWNID(REPOSITORY_EXPIRE, "repository:expire"),
-/* which things does this repo provides updates for, if it does */
+
+/* which things does this repo provides updates for, if it does (array) */
KNOWNID(REPOSITORY_UPDATES, "repository:updates"),
-/* which products this repository is supposed to be for */
+KNOWNID(REPOSITORY_UPDATE_LABEL, "repository:update:label"),
+KNOWNID(REPOSITORY_UPDATE_CPEID, "repository:update:cpeid"),
+
+/* which products this repository is supposed to be for (array) */
KNOWNID(REPOSITORY_PRODUCTS, "repository:products"),
+KNOWNID(REPOSITORY_PRODUCT_LABEL, "repository:product:label"),
+KNOWNID(REPOSITORY_PRODUCT_CPEID, "repository:product:cpeid"),
+
/* keyword (tags) for this repository */
KNOWNID(REPOSITORY_KEYWORDS, "repository:keywords"),
/* revision of the repository. arbitrary string */
struct stateswitch *swtab[NUMSTATES];
enum state sbtab[NUMSTATES];
int timestamp;
+ /* handles for collection
+ structures */
+ /* repo updates */
+ Id ruhandle;
+ /* repo products */
+ Id rphandle;
};
/*
case STATE_KEYWORD: break;
case STATE_CONTENT: break;
case STATE_REVISION: break;
- case STATE_DISTRO: break;
+ case STATE_DISTRO:
+ {
+ /* this is extra metadata about the product this repository
+ was designed for */
+ const char *cpeid = find_attr("cpeid", atts);
+ pd->rphandle = repodata_new_handle(pd->data);
+ /* set the cpeid for the product
+ the label is set in the content of the tag */
+ if (cpeid)
+ repodata_set_poolstr(pd->data, pd->rphandle, REPOSITORY_PRODUCT_CPEID, cpeid);
+ break;
+ }
case STATE_DATA: break;
case STATE_LOCATION: break;
case STATE_CHECKSUM: break;
if (pd->content)
repodata_add_poolstr_array(pd->data, SOLVID_META, REPOSITORY_REVISION, pd->content);
break;
- case STATE_DISTRO: break;
+ case STATE_DISTRO:
+ /* distro tag is used in repomd.xml to say the product this repo is
+ made for */
+ if (pd->content)
+ repodata_set_str(pd->data, pd->rphandle, REPOSITORY_PRODUCT_LABEL, pd->content);
+ repodata_add_flexarray(pd->data, SOLVID_META, REPOSITORY_PRODUCTS, pd->rphandle);
+ break;
case STATE_SUSEINFO: break;
case STATE_PRODUCTS: break;
case STATE_KEYWORDS: break;