| PackageKit Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Object Hierarchy | ||||
#define PK_SERVICE_PACK_ERROR #define PK_SERVICE_PACK_FILE_EXTENSION #define PK_SERVICE_PACK_TYPE_ERROR struct PkServicePack; struct PkServicePackClass; enum PkServicePackError; gboolean pk_service_pack_check_valid (PkServicePack *pack,const gchar *filename,GError **error); void pk_service_pack_create_for_package_ids_async (PkServicePack *pack,const gchar *filename,gchar **package_ids,gchar **package_ids_exclude,GCancellable *cancellable,PkProgressCallback progress_callback,gpointer progress_user_data,GAsyncReadyCallback callback,gpointer user_data); void pk_service_pack_create_for_updates_async (PkServicePack *pack,const gchar *filename,gchar **package_ids_exclude,GCancellable *cancellable,PkProgressCallback progress_callback,gpointer progress_user_data,GAsyncReadyCallback callback,gpointer user_data); GQuark pk_service_pack_error_quark (void); gboolean pk_service_pack_generic_finish (PkServicePack *pack,GAsyncResult *res,GError **error); PkServicePack * pk_service_pack_new (void); gboolean pk_service_pack_set_temp_directory (PkServicePack *pack,const gchar *directory); void pk_service_pack_test (gpointer user_data);
struct PkServicePackClass {
GObjectClass parent_class;
/* Padding for future expansion */
void (*_pk_reserved1) (void);
void (*_pk_reserved2) (void);
void (*_pk_reserved3) (void);
void (*_pk_reserved4) (void);
};
typedef enum {
PK_SERVICE_PACK_ERROR_FAILED_SETUP,
PK_SERVICE_PACK_ERROR_FAILED_DOWNLOAD,
PK_SERVICE_PACK_ERROR_FAILED_EXTRACTION,
PK_SERVICE_PACK_ERROR_FAILED_CREATE,
PK_SERVICE_PACK_ERROR_NOTHING_TO_DO,
PK_SERVICE_PACK_ERROR_NOT_COMPATIBLE
} PkServicePackError;
gboolean pk_service_pack_check_valid (PkServicePack *pack,const gchar *filename,GError **error);
Checks to see if a service pack file is valid, and usable with this system.
|
a valid PkServicePack instance |
|
the filename of the pack to check |
|
a GError to put the error code and message in, or NULL
|
Returns : |
TRUE if the service pack is valid |
Since 0.5.2
void pk_service_pack_create_for_package_ids_async (PkServicePack *pack,const gchar *filename,gchar **package_ids,gchar **package_ids_exclude,GCancellable *cancellable,PkProgressCallback progress_callback,gpointer progress_user_data,GAsyncReadyCallback callback,gpointer user_data);
Create a service pack for the specified Package IDs
|
a valid PkServicePack instance |
|
the filename of the service pack |
|
a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora" |
|
An array of packages to exclude, or NULL
|
|
a GCancellable or NULL
|
|
the function to run on completion |
|
the function to run when the progress changes. [scope call] |
|
data to pass to progress_callback
|
|
the data to pass to callback
|
Since 0.5.2
void pk_service_pack_create_for_updates_async (PkServicePack *pack,const gchar *filename,gchar **package_ids_exclude,GCancellable *cancellable,PkProgressCallback progress_callback,gpointer progress_user_data,GAsyncReadyCallback callback,gpointer user_data);
Create a service pack for the specified Package IDs
|
a valid PkServicePack instance |
|
the filename of the service pack |
|
An array of packages to exclude, or NULL
|
|
a GCancellable or NULL
|
|
the function to run on completion |
|
the function to run when the progress changes. [scope call] |
|
data to pass to progress_callback
|
|
the data to pass to callback
|
Since 0.5.2
GQuark pk_service_pack_error_quark (void);
Returns : |
Our personal error quark. |
Since 0.5.2
gboolean pk_service_pack_generic_finish (PkServicePack *pack,GAsyncResult *res,GError **error);
Gets the result from the asynchronous function.
|
a valid PkServicePack instance |
|
the GAsyncResult |
|
A GError or NULL
|
Returns : |
TRUE for success |
Since 0.5.2
PkServicePack * pk_service_pack_new (void);
Returns : |
A new service_pack class instance. |
Since 0.5.2
gboolean pk_service_pack_set_temp_directory (PkServicePack *pack,const gchar *directory);
Sets the directory to use when decompressing the service pack
|
a valid PkServicePack instance |
|
the directory to use, or NULL to use the default |
Returns : |
TRUE if the directory was set |
Since 0.5.2