## PkTask PkTask — An abstract package task GObject, dealing with unsigned transactions, GPG keys and EULA requests. |

## Synopsis

    #define             PK_TASK_TYPE_ERROR
                        PkTaskPrivate;
                        PkTask;
                        PkTaskClass;
    PkTask *            pk_task_new                         (void);
    void                pk_task_test                        (gpointer user_data);
    PkResults *         pk_task_generic_finish              (PkTask *task,
                                                             GAsyncResult *res,
                                                             GError **error);
    void                pk_task_install_packages_async      (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_update_packages_async       (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_remove_packages_async       (PkTask *task,
                                                             gchar **package_ids,
                                                             gboolean allow_deps,
                                                             gboolean autoremove,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_install_files_async         (PkTask *task,
                                                             gchar **files,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_update_system_async         (PkTask *task,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_resolve_async               (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **packages,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_search_names_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_search_details_async        (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_search_groups_async         (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_search_files_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_details_async           (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_update_detail_async     (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_download_packages_async     (PkTask *task,
                                                             gchar **package_ids,
                                                             const gchar *directory,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_updates_async           (PkTask *task,
                                                             PkBitfield filters,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_depends_async           (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **package_ids,
                                                             gboolean recursive,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_packages_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_requires_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **package_ids,
                                                             gboolean recursive,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_what_provides_async         (PkTask *task,
                                                             PkBitfield filters,
                                                             PkProvidesEnum provides,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_files_async             (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_categories_async        (PkTask *task,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_refresh_cache_async         (PkTask *task,
                                                             gboolean force,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_rollback_async              (PkTask *task,
                                                             const gchar *transaction_id,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_get_repo_list_async         (PkTask *task,
                                                             PkBitfield filters,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    void                pk_task_repo_enable_async           (PkTask *task,
                                                             const gchar *repo_id,
                                                             gboolean enabled,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);
    gboolean            pk_task_user_accepted               (PkTask *task,
                                                             guint request);
    gboolean            pk_task_user_declined               (PkTask *task,
                                                             guint request);

## Object Hierarchy

      GObject
       +----PkClient
             +----PkTask
                   +----PkTaskText
                   +----PkTaskWrapper

## Properties

      "interactive"              gboolean              : Read / Write
      "simulate"                 gboolean              : Read / Write

## Description

## Details

### PK_TASK_TYPE_ERROR

    #define PK_TASK_TYPE_ERROR (pk_task_error_get_type ())

### PkTaskPrivate

    typedef struct _PkTaskPrivate PkTaskPrivate;

Private PkTask data

### PkTask

    typedef struct _PkTask PkTask;

### PkTaskClass

    typedef struct {
    	PkClientClass		parent_class;
    	void	 (*untrusted_question)			(PkTask			*task,
    							 guint			 request,
    							 PkResults		*results);
    	void	 (*key_question)			(PkTask			*task,
    							 guint			 request,
    							 PkResults		*results);
    	void	 (*eula_question)			(PkTask			*task,
    							 guint			 request,
    							 PkResults		*results);
    	void	 (*media_change_question)		(PkTask			*task,
    							 guint			 request,
    							 PkResults		*results);
    	void	 (*simulate_question)			(PkTask			*task,
    							 guint			 request,
    							 PkResults		*results);
    	/* padding for future expansion */
    	void (*_pk_reserved1) (void);
    	void (*_pk_reserved2) (void);
    	void (*_pk_reserved3) (void);
    	void (*_pk_reserved4) (void);
    	void (*_pk_reserved5) (void);
    } PkTaskClass;

### pk_task_new ()

    PkTask *            pk_task_new                         (void);

Returns : | a new PkTask object.

Since 0.5.2

### pk_task_test ()

    void                pk_task_test                        (gpointer user_data);

`user_data` : |

### pk_task_generic_finish ()

    PkResults *         pk_task_generic_finish              (PkTask *task,
                                                             GAsyncResult *res,
                                                             GError **error);

Gets the result from the asynchronous function.

`task` : | a valid PkTask instance
`res` : | the GAsyncResult
`error` : | A GError or `NULL`
Returns : | The PkResults of the transaction. [transfer full]

Since 0.5.2

### pk_task_install_packages_async ()

    void                pk_task_install_packages_async      (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Merges in details about packages using resolve.

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.5.2

### pk_task_update_packages_async ()

    void                pk_task_update_packages_async       (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Update specific packages to the newest available versions.

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback_ready`

Since 0.5.2

### pk_task_remove_packages_async ()

    void                pk_task_remove_packages_async       (PkTask *task,
                                                             gchar **package_ids,
                                                             gboolean allow_deps,
                                                             gboolean autoremove,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Remove a package (optionally with dependancies) from the system. If `allow_deps` is set to `FALSE`, and other packages would have to be removed, then the transaction would fail.

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`allow_deps` : | if other dependant packages are allowed to be removed from the computer
`autoremove` : | if other packages installed at the same time should be tried to remove
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback_ready`

Since 0.5.2

### pk_task_install_files_async ()

    void                pk_task_install_files_async         (PkTask *task,
                                                             gchar **files,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Install a file locally, and get the deps from the repositories. This is useful for double clicking on a .rpm or .deb file.

`task` : | a valid PkTask instance
`files` : | a file such as "/home/hughsie/Desktop/hal-devel-0.10.0.rpm"
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback_ready`

Since 0.5.2

### pk_task_update_system_async ()

    void                pk_task_update_system_async         (PkTask *task,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Update all the packages on the system with the highest versions found in all repositories. NOTE: you can't choose what repositories to update from, but you can do: - `pk_task_repo_disable()` - `pk_task_update_system()` - `pk_task_repo_enable()`

`task` : | a valid PkTask instance
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback_ready`

Since 0.5.2

### pk_task_resolve_async ()

    void                pk_task_resolve_async               (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **packages,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Resolves a package name to a package-id.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`packages` : | package names to find
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_search_names_async ()

    void                pk_task_search_names_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Searches for a package name.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`values` : | search values
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_search_details_async ()

    void                pk_task_search_details_async        (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Searches for some package details.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`values` : | search values
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_search_groups_async ()

    void                pk_task_search_groups_async         (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Searches the group lists.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`values` : | search values
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_search_files_async ()

    void                pk_task_search_files_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Searches for specific files.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`values` : | search values
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_details_async ()

    void                pk_task_get_details_async           (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Gets details about packages.

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_update_detail_async ()

    void                pk_task_get_update_detail_async     (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Gets details about updates.

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_download_packages_async ()

    void                pk_task_download_packages_async     (PkTask *task,
                                                             gchar **package_ids,
                                                             const gchar *directory,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Downloads packages

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`directory` : | the destination directory
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_updates_async ()

    void                pk_task_get_updates_async           (PkTask *task,
                                                             PkBitfield filters,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Gets the update lists.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_depends_async ()

    void                pk_task_get_depends_async           (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **package_ids,
                                                             gboolean recursive,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Get the list of dependant packages.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`recursive` : | if we should recurse to packages that depend on other packages
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_packages_async ()

    void                pk_task_get_packages_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Gets the list of packages.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_requires_async ()

    void                pk_task_get_requires_async          (PkTask *task,
                                                             PkBitfield filters,
                                                             gchar **package_ids,
                                                             gboolean recursive,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Get the packages this package requires.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`recursive` : | if we should return packages that depend on the ones we do
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_what_provides_async ()

    void                pk_task_what_provides_async         (PkTask *task,
                                                             PkBitfield filters,
                                                             PkProvidesEnum provides,
                                                             gchar **values,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Find the package that provides some resource.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`provides` : | a PkProvidesEnum type
`values` : | values to search for
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_files_async ()

    void                pk_task_get_files_async             (PkTask *task,
                                                             gchar **package_ids,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Get the files in a package.

`task` : | a valid PkTask instance
`package_ids` : | a null terminated array of package_id structures such as "hal;0.0.1;i386;fedora"
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_categories_async ()

    void                pk_task_get_categories_async        (PkTask *task,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Get the categories available.

`task` : | a valid PkTask instance
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_refresh_cache_async ()

    void                pk_task_refresh_cache_async         (PkTask *task,
                                                             gboolean force,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Refresh the package cache.

`task` : | a valid PkTask instance
`force` : | if the metadata should be deleted and re-downloaded even if it is correct
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_rollback_async ()

    void                pk_task_rollback_async              (PkTask *task,
                                                             const gchar *transaction_id,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Rollback to a previous package state.

`task` : | a valid PkTask instance
`transaction_id` : | The transaction ID of the old transaction
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_get_repo_list_async ()

    void                pk_task_get_repo_list_async         (PkTask *task,
                                                             PkBitfield filters,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Get the list of available repositories.

`task` : | a valid PkTask instance
`filters` : | a bitfield of filters that can be used to limit the results
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_repo_enable_async ()

    void                pk_task_repo_enable_async           (PkTask *task,
                                                             const gchar *repo_id,
                                                             gboolean enabled,
                                                             GCancellable *cancellable,
                                                             PkProgressCallback progress_callback,
                                                             gpointer progress_user_data,
                                                             GAsyncReadyCallback callback_ready,
                                                             gpointer user_data);

Enable or disable a specific repo.

`task` : | a valid PkTask instance
`repo_id` : | The software source ID
`enabled` : | `TRUE` or `FALSE`
`cancellable` : | a GCancellable or `NULL`
`progress_callback` : | the function to run when the progress changes. [scope call]
`progress_user_data` : | data to pass to `progress_callback`
`callback_ready` : | the function to run on completion
`user_data` : | the data to pass to `callback`

Since 0.6.5

### pk_task_user_accepted ()

    gboolean            pk_task_user_accepted               (PkTask *task,
                                                             guint request);

`task` : |
`request` : |
Returns : |

Since 0.5.2

### pk_task_user_declined ()

    gboolean            pk_task_user_declined               (PkTask *task,
                                                             guint request);

`task` : |
`request` : |
Returns : |

Since 0.5.2

## Property Details

### The `"interactive"` property

      "interactive"              gboolean              : Read / Write

Default value: TRUE

Since 0.6.7

### The `"simulate"` property

      "simulate"                 gboolean              : Read / Write

Default value: TRUE

Since 0.5.2