PackageKitGlib.Results

g GObject.Object GObject.Object PackageKitGlib.Results PackageKitGlib.Results GObject.Object->PackageKitGlib.Results

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

new ()

add_category (item)

add_details (item)

add_distro_upgrade (item)

add_eula_required (item)

add_files (item)

add_media_change_required (item)

add_package (item)

add_repo_detail (item)

add_repo_signature_required (item)

add_require_restart (item)

add_transaction (item)

add_update_detail (item)

get_category_array ()

get_details_array ()

get_distro_upgrade_array ()

get_error_code ()

get_eula_required_array ()

get_exit_code ()

get_files_array ()

get_media_change_required_array ()

get_package_array ()

get_package_sack ()

get_repo_detail_array ()

get_repo_signature_required_array ()

get_require_restart_array ()

get_require_restart_worst ()

get_role ()

get_transaction_array ()

get_transaction_flags ()

get_update_detail_array ()

set_error_code (item)

set_exit_code (exit_enum)

set_role (role)

Virtual Methods

Inherited:

GObject.Object (7)

Properties

Name

Type

Flags

Short Description

inputs

int

r/w

progress

PackageKitGlib.Progress

r/w

The progress instance

role

PackageKitGlib.RoleEnum

r/w

transaction-flags

int

r/w

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent

GObject.Object

r

priv

PackageKitGlib.ResultsPrivate

r

Class Details

class PackageKitGlib.Results(**kwargs)
Bases:

GObject.Object

Abstract:

No

Structure:

PackageKitGlib.ResultsClass

classmethod new()
Returns:

a new PackageKitGlib.Results object.

Return type:

PackageKitGlib.Results

New in version 0.5.2.

add_category(item)
Parameters:

item (PackageKitGlib.Category) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds a category item to the results set.

New in version 0.5.2.

add_details(item)
Parameters:

item (PackageKitGlib.Details) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some package details to the results set.

New in version 0.5.2.

add_distro_upgrade(item)
Parameters:

item (PackageKitGlib.DistroUpgrade) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds a distribution upgrade item to the results set.

New in version 0.5.2.

add_eula_required(item)
Parameters:

item (PackageKitGlib.EulaRequired) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some EULA details to the results set.

New in version 0.5.2.

add_files(item)
Parameters:

item (PackageKitGlib.Files) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some files details to the results set.

New in version 0.5.2.

add_media_change_required(item)
Parameters:

item (PackageKitGlib.MediaChangeRequired) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some media change details to the results set.

New in version 0.5.2.

add_package(item)
Parameters:

item (PackageKitGlib.Package) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds a package to the results set.

New in version 0.5.3.

add_repo_detail(item)
Parameters:

item (PackageKitGlib.RepoDetail) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some repository details to the results set.

New in version 0.5.2.

add_repo_signature_required(item)
Parameters:

item (PackageKitGlib.RepoSignatureRequired) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some repository signature details to the results set.

New in version 0.5.2.

add_require_restart(item)
Parameters:

item (PackageKitGlib.RequireRestart) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds a require restart item to the results set.

New in version 0.5.2.

add_transaction(item)
Parameters:

item (PackageKitGlib.TransactionPast) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds a transaction item to the results set.

New in version 0.5.2.

add_update_detail(item)
Parameters:

item (PackageKitGlib.UpdateDetail) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some update details to the results set.

New in version 0.5.2.

get_category_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.Category's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.Category]

Gets the categories from the transaction.

New in version 0.5.2.

get_details_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.Details's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.Details]

Gets the package details from the transaction.

New in version 0.5.2.

get_distro_upgrade_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.DistroUpgrade's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.DistroUpgrade]

Gets the distribution upgrades from the transaction.

New in version 0.5.2.

get_error_code()
Returns:

A PackageKitGlib.Error, or None, free with GObject.Object.unref()

Return type:

PackageKitGlib.Error

Gets the last error code from the transaction.

New in version 0.5.2.

get_eula_required_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.EulaRequired's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.EulaRequired]

Gets the eulas required from the transaction.

New in version 0.5.2.

get_exit_code()
Returns:

The PackageKitGlib.ExitEnum or PackageKitGlib.ExitEnum.UNKNOWN for error or if it was not set

Return type:

PackageKitGlib.ExitEnum

Gets the exit enum. You probably don’t want to be using this function, and instead using the much more useful PackageKitGlib.Results.get_error_code() function.

New in version 0.5.2.

get_files_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.Files's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.Files]

Gets the files from the transaction.

New in version 0.5.2.

get_media_change_required_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.MediaChangeRequired's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.MediaChangeRequired]

Gets the media changes required from the transaction.

New in version 0.5.2.

get_package_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.Package's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.Package]

Gets the packages from the transaction.

New in version 0.5.2.

get_package_sack()
Returns:

A PackageKitGlib.PackageSack of data, GObject.Object.unref() to free.

Return type:

PackageKitGlib.PackageSack

Gets a package sack from the transaction.

New in version 0.5.2.

get_repo_detail_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.RepoDetail's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.RepoDetail]

Gets the repository details from the transaction.

New in version 0.5.2.

get_repo_signature_required_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.RepoSignatureRequired's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.RepoSignatureRequired]

Gets the repository signatures required from the transaction.

New in version 0.5.2.

get_require_restart_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.RequireRestart's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.RequireRestart]

Gets the require restarts from the transaction.

New in version 0.5.2.

get_require_restart_worst()
Returns:

a PackageKitGlib.RestartEnum value, e.g. PackageKitGlib.RestartEnum.SYSTEM

Return type:

PackageKitGlib.RestartEnum

This method returns the ‘worst’ restart of all the transactions. It is needed as multiple sub-transactions may emit require-restart with different values, and we always want to get the most invasive of all.

For instance, if a transaction emits RequireRestart(system) and then RequireRestart(session) then pk_client_get_require_restart will return system as a session restart is implied with a system restart.

New in version 0.5.2.

get_role()
Returns:

The PackageKitGlib.RoleEnum or PackageKitGlib.RoleEnum.UNKNOWN if not set

Return type:

PackageKitGlib.RoleEnum

Gets the role that produced these results.

New in version 0.7.5.

get_transaction_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.TransactionPast's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.TransactionPast]

Gets the transactions from the transaction.

New in version 0.5.2.

get_transaction_flags()
Returns:

a #PkBitfield containing PackageKitGlib.TransactionFlagEnum 0 if not set

Return type:

int

Gets the transaction flag for these results.

New in version 0.8.1.

get_update_detail_array()
Returns:

A GLib.PtrArray array of PackageKitGlib.UpdateDetail's, free with g_ptr_array_unref().

Return type:

[PackageKitGlib.UpdateDetail]

Gets the update details from the transaction.

New in version 0.5.2.

set_error_code(item)
Parameters:

item (PackageKitGlib.Error) – the object to add to the array

Returns:

True if the value was set

Return type:

bool

Adds some error details to the results set.

New in version 0.5.2.

set_exit_code(exit_enum)
Parameters:

exit_enum (PackageKitGlib.ExitEnum) – the exit code

Returns:

True if the value was set

Return type:

bool

Sets the results object to have the given exit code.

New in version 0.5.2.

set_role(role)
Parameters:

role (PackageKitGlib.RoleEnum) – the role enum

Returns:

True if the value was set

Return type:

bool

Sets the results object to have the given role enum.

New in version 1.1.8.

Property Details

PackageKitGlib.Results.props.inputs
Name:

inputs

Type:

int

Default Value:

0

Flags:

READABLE, WRITABLE

New in version 0.5.3.

PackageKitGlib.Results.props.progress
Name:

progress

Type:

PackageKitGlib.Progress

Default Value:

None

Flags:

READABLE, WRITABLE

The progress instance

New in version 0.5.3.

PackageKitGlib.Results.props.role
Name:

role

Type:

PackageKitGlib.RoleEnum

Default Value:

PackageKitGlib.RoleEnum.UNKNOWN

Flags:

READABLE, WRITABLE

The PackageKitGlib.RoleEnum or PackageKitGlib.RoleEnum.UNKNOWN if not set

New in version 0.5.2.

PackageKitGlib.Results.props.transaction_flags
Name:

transaction-flags

Type:

int

Default Value:

0

Flags:

READABLE, WRITABLE

A #PkBitfield containing PackageKitGlib.TransactionFlagEnum for this result.

New in version 0.8.1.