AppStreamGlib.Translation

g AppStreamGlib.Translation AppStreamGlib.Translation GObject.Object GObject.Object GObject.Object->AppStreamGlib.Translation

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

kind_from_string (kind)

class

kind_to_string (kind)

class

new ()

get_id ()

get_kind ()

set_id (id)

set_kind (kind)

Virtual Methods

Inherited:

GObject.Object (7)

Properties

None

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent_instance

GObject.Object

r

Class Details

class AppStreamGlib.Translation(**kwargs)
Bases:

GObject.Object

Abstract:

No

Structure:

AppStreamGlib.TranslationClass

classmethod kind_from_string(kind)[source]
Parameters:

kind (str) – the string.

Returns:

a AppStreamGlib.TranslationKind, or AppStreamGlib.TranslationKind.UNKNOWN for unknown.

Return type:

AppStreamGlib.TranslationKind

Converts the text representation to an enumerated value.

New in version 0.5.8.

classmethod kind_to_string(kind)[source]
Parameters:

kind (AppStreamGlib.TranslationKind) – the AppStreamGlib.TranslationKind.

Returns:

string version of kind

Return type:

str

Converts the enumerated value to an text representation.

New in version 0.5.8.

classmethod new()[source]
Returns:

a AppStreamGlib.Translation

Return type:

AppStreamGlib.Translation

Creates a new AppStreamGlib.Translation.

New in version 0.5.8.

get_id()[source]
Returns:

ID, e.g. “foobar-1.0.2”

Return type:

str

Gets the ID for this translation.

New in version 0.5.8.

get_kind()[source]
Returns:

the AppStreamGlib.TranslationKind

Return type:

AppStreamGlib.TranslationKind

Gets the translation kind.

New in version 0.5.8.

set_id(id)[source]
Parameters:

id (str) – the URL.

Sets the ID for this translation.

New in version 0.5.8.

set_kind(kind)[source]
Parameters:

kind (AppStreamGlib.TranslationKind) – the AppStreamGlib.TranslationKind, e.g. %AS_TRANSLATION_KIND_THUMBNAIL.

Sets the translation kind.

New in version 0.5.8.