Convert an Component to metainfo data.
This will always be XML, YAML is no valid format for metainfo files.
The amount of localization included in the metadata depends on how the Component was initially loaded and whether it contains data for all locale.
The first Component added to the internal list will be transformed. In case no component is present, null is returned.
this |
An instance of Metadata. |
format |
The format to use (XML or YAML) |
A string containing the XML metadata. Free with g_free |