AsDEP11 3 APPSTREAM Library
AsDEP11

## Functions

AsDEP11 * | as_dep11_new ()
const gchar * | as_dep11_get_locale ()
void | as_dep11_set_locale ()
void | as_dep11_parse_data ()
void | as_dep11_parse_file ()
GPtrArray * | as_dep11_get_components ()
void | as_dep11_clear_components ()

## Object Hierarchy

        GObject
        ╰── AsDEP11

## Description

## Functions

### as_dep11_new ()

    AsDEP11 *
    as_dep11_new (void);

#### Returns

as_dep11_new

### as_dep11_get_locale ()

    const gchar *
    as_dep11_get_locale (AsDEP11 *dep11);

Gets the current active locale for parsing DEP-11 metadata., or "ALL" if all locales are read.

#### Parameters

dep11 | a AsDEP11 instance. |

#### Returns

Locale used for metadata parsing.

as_dep11_get_locale

### as_dep11_set_locale ()

    void
    as_dep11_set_locale (AsDEP11 *dep11,
                         const gchar *locale);

Sets the locale which should be read when processing DEP-11 metadata. All other locales are ignored, which increases parsing speed and reduces memory usage. If you set the locale to "ALL", all locales will be read.

#### Parameters

dep11 | a AsDEP11 instance. |
locale | the locale. |

as_dep11_set_locale

### as_dep11_parse_data ()

    void
    as_dep11_parse_data (AsDEP11 *dep11,
                         const gchar *data,
                         GError **error);

as_dep11_parse_data

### as_dep11_parse_file ()

    void
    as_dep11_parse_file (AsDEP11 *dep11,
                         GFile *file,
                         GError **error);

Parses an AppStream upstream metadata file in DEP-11-YAML format.

#### Parameters

dep11 | A valid AsDEP11 instance |
file | GFile for the upstream metadata |
error | A GError or `NULL`. |

as_dep11_parse_file

### as_dep11_get_components ()

    GPtrArray *
    as_dep11_get_components (AsDEP11 *dep11);

#### Parameters

dep11 | an AsDEP11 instance. |

#### Returns

A GPtrArray of all parsed components.

[transfer none][element-type AsComponent]

as_dep11_get_components

### as_dep11_clear_components ()

    void
    as_dep11_clear_components (AsDEP11 *dep11);

as_dep11_clear_components

## Types and Values