AppStream.Artifact¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
None
Signals¶
- Inherited:
Fields¶
- Inherited:
Name |
Type |
Access |
Description |
|---|---|---|---|
parent_instance |
r |
Class Details¶
- class AppStream.Artifact(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
- classmethod new()¶
- Returns:
- Return type:
Creates a new
AppStream.Artifact.
- add_checksum(cs)¶
- Parameters:
cs (
AppStream.Checksum) – TheAppStream.Checksum.
Add a checksum for the file associated with this artifact.
- add_location(location)¶
- Parameters:
location (
str) – An URL of the download location
Adds a artifact location.
- get_bundle_kind()¶
- Returns:
- Return type:
Gets the bundle kind of this artifact.
- get_checksum(kind)¶
- Parameters:
kind (
AppStream.ChecksumKind) –- Returns:
an
AppStream.Checksum, orNonefor not set or invalid- Return type:
Gets the artifact checksum
- get_checksums()¶
- Returns:
an array of
AppStream.Checksumobjects.- Return type:
Get a list of all checksums we have for this artifact.
- get_filename()¶
- Returns:
The platform triplet or identifier string.
- Return type:
Gets a suggested filename for the downloaded artifact, or
Noneif none is suggested.
- get_kind()¶
- Returns:
- Return type:
Gets the artifact kind.
- get_locations()¶
- Returns:
list of locations
- Return type:
[
str]
Gets the artifact locations, typically URLs.
- get_platform()¶
- Returns:
The platform triplet or identifier string.
- Return type:
Gets the artifact platform string (e.g. a triplet like “x86_64-linux-gnu”).
- get_size(kind)¶
- Parameters:
kind (
AppStream.SizeKind) – aAppStream.SizeKind- Returns:
The size of the given kind of this artifact.
- Return type:
Gets the artifact size.
- set_bundle_kind(kind)¶
- Parameters:
kind (
AppStream.BundleKind) – theAppStream.BundleKind, e.g.AppStream.BundleKind.TARBALL.
Sets the bundle kind for this release artifact.
- set_filename(filename)¶
- Parameters:
filename (
str) – the file name suggestion.
Sets a suggested filename for this artifact after it has been downloaded.
- set_kind(kind)¶
- Parameters:
kind (
AppStream.ArtifactKind) – theAppStream.ArtifactKind, e.g.AppStream.ArtifactKind.SOURCE.
Sets the artifact kind.
- set_platform(platform)¶
- Parameters:
platform (
str) – the platform triplet.
Sets the artifact platform triplet or identifier string.
- set_size(size, kind)¶
- Parameters:
size (
int) – a size in bytes, or 0 for unknownkind (
AppStream.SizeKind) – aAppStream.SizeKind
Sets the artifact size for the given kind.