Flatpak.Ref

g Flatpak.Ref Flatpak.Ref GObject.Object GObject.Object GObject.Object->Flatpak.Ref

Subclasses:

Flatpak.BundleRef, Flatpak.InstalledRef, Flatpak.RelatedRef, Flatpak.RemoteRef

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

parse (ref)

format_ref ()

format_ref_cached ()

get_arch ()

get_branch ()

get_collection_id ()

get_commit ()

get_kind ()

get_name ()

Virtual Methods

Inherited:

GObject.Object (7)

Properties

Name

Type

Flags

Short Description

arch

str

r/w/co

The architecture of the application or runtime

branch

str

r/w/co

The branch of the application or runtime

collection-id

str

r/w/co

The collection ID

commit

str

r/w/co

The commit

kind

Flatpak.RefKind

r/w/co

The kind of artifact

name

str

r/w/co

The name of the application or runtime

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent

GObject.Object

r

Class Details

class Flatpak.Ref(**kwargs)
Bases:

GObject.Object

Abstract:

No

Structure:

Flatpak.RefClass

classmethod parse(ref)
Parameters:

ref (str) – A string ref name, such as “app/org.test.App/x86_64/master”

Raises:

GLib.Error

Returns:

an Flatpak.Ref, or None

Return type:

Flatpak.Ref

Tries to parse a full ref name and return a Flatpak.Ref (without a commit set) or fail if the ref is invalid somehow.

format_ref()
Returns:

string representation

Return type:

str

Convert an Flatpak.Ref object into a string representation that can be parsed by Flatpak.Ref.parse().

format_ref_cached()
Returns:

string representation

Return type:

str

Like Flatpak.Ref.format_ref() but this returns the same string each time it’s called rather than allocating a new one.

New in version 1.9.1.

get_arch()
Returns:

the arch

Return type:

str

Gets the arch or the ref.

get_branch()
Returns:

the branch

Return type:

str

Gets the branch of the ref.

get_collection_id()
Returns:

the collection ID

Return type:

str

Gets the collection ID of the ref.

get_commit()
Returns:

the commit

Return type:

str

Gets the commit of the ref.

get_kind()
Returns:

the kind of artifact

Return type:

Flatpak.RefKind

Gets the kind of artifact that this ref refers to.

get_name()
Returns:

the name

Return type:

str

Gets the name of the ref.

Property Details

Flatpak.Ref.props.arch
Name:

arch

Type:

str

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The architecture of the application or runtime

Flatpak.Ref.props.branch
Name:

branch

Type:

str

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The branch of the application or runtime

Flatpak.Ref.props.collection_id
Name:

collection-id

Type:

str

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The collection ID

Flatpak.Ref.props.commit
Name:

commit

Type:

str

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The commit

Flatpak.Ref.props.kind
Name:

kind

Type:

Flatpak.RefKind

Default Value:

Flatpak.RefKind.APP

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The kind of artifact

Flatpak.Ref.props.name
Name:

name

Type:

str

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The name of the application or runtime