- public void add_addon (Component addon)
Add a reference to the addon that is enhancing this component.
- public void add_agreement (Agreement agreement)
Adds an agreement to the software component.
- public void add_bundle (Bundle bundle)
Adds a bundle to the component.
- public void add_category (string category)
Add a category.
- public void add_content_rating (ContentRating content_rating)
Adds a content rating to this component.
- public void add_extends (string cpt_id)
Add a reference to the extended component
- public void add_icon (Icon icon)
Add an icon to this component.
- public void add_language (string? locale, int percentage)
Adds a language to the component.
- public void add_launchable (Launchable launchable)
Adds a Launchable
containing launchables entries for this component.
- public void add_provided (Provided prov)
Add a set of provided items to this component.
- public void add_provided_item (ProvidedKind kind, string item)
Adds a provided item to the component with the given kind
, creating a new AsProvided
for this kind internally if necessary.
- public void add_relation (Relation relation)
Adds a Relation to
set a recommends or requires relation of component this on the item mentioned in the
Relation.
- public void add_release (Release release)
- public void add_review (Review review)
Adds a user review to a software component.
- public void add_screenshot (Screenshot sshot)
- public void add_suggested (Suggested suggested)
- public bool add_tag (string ns, string tag)
Add a tag to this component.
- public void add_translation (Translation tr)
Assign an
Translation object describing the translation system used by this component.
- public void add_url (UrlKind url_kind, string url)
Adds some URL data to the component.
- public void clear_languages ()
Remove all registered language translation information.
- public void clear_tags ()
Remove all tags associated with this component.
- public unowned string get_active_locale ()
Get the current active locale for this component, which is used to get
localized messages.
- public unowned GenericArray<Component> get_addons ()
Returns a list of Component objects which
are addons extending this component in functionality.
- public unowned Agreement? get_agreement_by_kind (AgreementKind kind)
Gets an agreement the component has specified for the particular kind.
- public unowned GenericArray<Agreement> get_agreements ()
Get a list of all agreements registered with this software component.
- public unowned string get_branch ()
Gets the branch for the application.
- public unowned Branding? get_branding ()
Get the branding associated with this component, or
null in case this component has no special branding.
- public unowned Bundle? get_bundle (BundleKind bundle_kind)
Gets a bundle identifier string.
- public unowned GenericArray<Bundle> get_bundles ()
Get a list of all software bundles associated with this component.
- public unowned GenericArray<string> get_categories ()
- public unowned GenericArray<string> get_compulsory_for_desktops ()
- public unowned ContentRating? get_content_rating (string kind)
Gets a content ratings of a specific type that are defined for this
component.
- public unowned GenericArray<ContentRating> get_content_ratings ()
Gets all content ratings defined for this software.
- public unowned Context? get_context ()
Get the Context
associated with this component.
- public unowned HashTable<void*,void*> get_custom ()
- public unowned string get_custom_value (string key)
Retrieve value for a custom data entry with the given key.
- public unowned string get_data_id ()
Get a unique identifier for this metadata set.
- public unowned string get_date_eol ()
Gets the end-of-life date for the entire component.
- public unowned string get_description ()
Get the localized long description of this component.
- public unowned string get_desktop_id ()
Get the Desktop Entry ID for this component, if it is of type
"desktop-application".
- public unowned string get_developer_name ()
Get the component's developer or development team name.
- public unowned GenericArray<string>? get_extends ()
Returns a string list of IDs of components which are extended by this
addon.
- public unowned Icon? get_icon_by_size (uint width, uint height)
Gets an icon matching the size constraints.
- public unowned Icon? get_icon_stock ()
Gets a stock icon for this component if one is associated with it.
- public unowned GenericArray<Icon> get_icons ()
- public unowned string get_id ()
Get the unique AppStream identifier for this component.
- public unowned string[] get_keywords ()
- public unowned HashTable<void*,void*> get_keywords_table ()
Retrieve the internal hash table mapping languages to keword arrays.
- public ComponentKind get_kind ()
- public int get_language (string? locale)
Gets the translation coverage in percent for a specific locale
- public List<unowned string> get_languages ()
Get a list of all languages.
- public unowned Launchable? get_launchable (LaunchableKind kind)
Gets a Launchable
of a specific type that contains launchable entries for this component.
- public unowned GenericArray<Launchable> get_launchables ()
- public MergeKind get_merge_kind ()
Get the merge method which should apply to duplicate components with
this ID.
- public unowned string get_metadata_license ()
The license the metadata iself is subjected to.
- public unowned string get_name ()
A human-readable name for this component.
- public unowned HashTable<void*,void*> get_name_table ()
Get the internal locale to component name mapping table.
- public unowned string get_name_variant_suffix ()
Get variant suffix for the component name (only to be displayed if two
components have the same name).
- public unowned string get_origin ()
- public unowned string get_pkgname ()
Get the first package name of the list of packages that need to be
installed for this component to be present on the system.
- public unowned string[] get_pkgnames ()
Get a list of package names which this component consists of.
- public int get_priority ()
Returns the priority of this component.
- public unowned string get_project_group ()
Get the component's project group.
- public unowned string get_project_license ()
Get the license of the project this component belongs to.
- public unowned GenericArray<Provided> get_provided ()
Get a list of Provided
objects associated with this component.
- public unowned Provided? get_provided_for_kind (ProvidedKind kind)
Get an Provided
object for the given interface type, containing information about the public interfaces (mimetypes, firmware, DBus services, ...) this
component provides.
- public unowned GenericArray<Relation> get_recommends ()
Get an array of items that are recommended by this component.
- public unowned GenericArray<Release> get_releases ()
Get an array of the
Release items this component provides.
- public unowned GenericArray<Relation> get_requires ()
Get an array of items that are required by this component.
- public unowned GenericArray<Review> get_reviews ()
Gets any reviews associated with the component.
- public ComponentScope get_scope ()
- public unowned GenericArray<Screenshot> get_screenshots ()
Get a list of associated screenshots.
- public GenericArray<unowned string> get_search_tokens ()
Returns all search tokens for this component.
- public uint get_sort_score ()
Returns the sorting priority of this component.
- public unowned string get_source_pkgname ()
- public unowned GenericArray<Suggested> get_suggested ()
Get a list of associated suggestions.
- public unowned string get_summary ()
Get a short description of this component.
- public unowned HashTable<void*,void*> get_summary_table ()
Get the internal locale to component summary mapping table.
- public unowned GenericArray<Relation> get_supports ()
Get an array of items that are supported by this component, e.
- public uint64 get_timestamp_eol ()
Gets the UNIX timestamp for the date when this component is out of
support (end-of-life) and will receive no more updates, not even security fixes.
- public unowned GenericArray<Translation> get_translations ()
Get a GenericArray of
Translation objects describing the translation systems and translation-ids (e.
- public unowned string? get_url (UrlKind url_kind)
Gets a URL.
- public ValueFlags get_value_flags ()
- public bool has_bundle ()
- public bool has_category (string category)
Check if component is in the specified category.
- public bool has_tag (string ns, string tag)
Test if the component is tagged with the selected tag.
- public bool insert_custom_value (string key, string value)
Add a key and value pair to the custom data table.
- public bool is_compulsory_for_desktop (string desktop)
Check if this component is compulsory for the given desktop.
- public bool is_ignored ()
- public bool is_member_of_category (Category category)
Test if the component this is a
member of category category
.
- public bool is_valid ()
Check if the essential properties of this Component are populated with
useful data.
- public bool load_from_bytes (Context context, FormatKind format, Bytes bytes) throws Error
Load metadata for this component from an XML string.
- public bool load_from_xml_data (Context context, string data) throws Error
Load metadata for this component from an XML string.
- public bool remove_tag (string ns, string tag)
Remove a tag from this component
- public uint search_matches (string term)
Searches component data for a specific keyword.
- public uint search_matches_all (string terms)
Searches component data for all the specific keywords.
- public void set_active_locale (string? locale)
Set the current active locale for this component, which is used to get
localized messages.
- public void set_branch (string branch)
Set the branch that the component instance was sourced from.
- public void set_branding (Branding branding)
Set branding for this component.
- public void set_compulsory_for_desktop (string desktop)
Mark this component to be compulsory for the specified desktop
environment.
- public void set_data_id (string value)
Set the session-specific unique metadata identifier for this
component.
- public void set_date_eol (string date)
Sets an end-of-life date for this component.
- public void set_description (string value, string? locale)
Set long description for this component.
- public void set_developer_name (string value, string? locale)
Set the the component's developer or development team name.
- public void set_id (string value)
Set the AppStream identifier for this component.
- public void set_keywords (string[] value, string? locale)
Set keywords for this component.
- public void set_kind (ComponentKind value)
- public void set_merge_kind (MergeKind kind)
- public void set_metadata_license (string value)
Set the license this metadata is licensed under.
- public void set_name (string value, string? locale)
Set a human-readable name for this component.
- public void set_name_variant_suffix (string value, string? locale)
Set a variant suffix for the component name (only to be displayed if
components have the same name).
- public void set_origin (string origin)
- public void set_pkgname (string pkgname)
Set the package name that provides this component.
- public void set_pkgnames (string[] packages)
Set a list of package names this component consists of.
- public void set_priority (int priority)
Sets the priority of this component.
- public void set_project_group (string value)
Set the component's project group.
- public void set_project_license (string value)
Set the project license.
- public void set_scope (ComponentScope scope)
- public void set_sort_score (uint score)
Sets the sorting score of this component.
- public void set_source_pkgname (string spkgname)
- public void set_summary (string value, string? locale)
Set a short description for this component.
- public void set_value_flags (ValueFlags flags)
- public string to_string ()
Returns a string identifying this component.
- public string to_xml_data (Context context) throws Error
Serialize this component into an XML string.