<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
<!ENTITY version SYSTEM "version.xml">
]>
<refentry id="PkPackageSack">
<refmeta>
<refentrytitle role="top_of_page" id="PkPackageSack.top_of_page">PkPackageSack</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>PACKAGEKIT Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>PkPackageSack</refname>
<refpurpose>A sack of packages that can be manipulated</refpurpose>
</refnamediv>

<refsynopsisdiv id="PkPackageSack.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>
#define             <link linkend="PK-PACKAGE-SACK-ERROR--CAPS">PK_PACKAGE_SACK_ERROR</link>
#define             <link linkend="PK-PACKAGE-SACK-TYPE-ERROR--CAPS">PK_PACKAGE_SACK_TYPE_ERROR</link>
                    <link linkend="PkPackageSackPrivate">PkPackageSackPrivate</link>;
                    <link linkend="PkPackageSackResults">PkPackageSackResults</link>;
                    <link linkend="PkPackageSack-struct">PkPackageSack</link>;
<link linkend="GQuark">GQuark</link>              <link linkend="pk-package-sack-error-quark">pk_package_sack_error_quark</link>         (void);
<link linkend="PkPackageSack">PkPackageSack</link> *     <link linkend="pk-package-sack-new">pk_package_sack_new</link>                 (void);
<link linkend="void">void</link>                <link linkend="pk-package-sack-test">pk_package_sack_test</link>                (<link linkend="gpointer">gpointer</link> user_data);
<link linkend="guint">guint</link>               <link linkend="pk-package-sack-get-size">pk_package_sack_get_size</link>            (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="PkPackage">PkPackage</link> *         <link linkend="pk-package-sack-get-index">pk_package_sack_get_index</link>           (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="guint">guint</link> i);
<link linkend="void">void</link>                <link linkend="pk-package-sack-clear">pk_package_sack_clear</link>               (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="gchar">gchar</link> **            <link linkend="pk-package-sack-get-ids">pk_package_sack_get_ids</link>             (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="void">void</link>                <link linkend="pk-package-sack-sort-package-id">pk_package_sack_sort_package_id</link>     (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="void">void</link>                <link linkend="pk-package-sack-sort-info">pk_package_sack_sort_info</link>           (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="void">void</link>                <link linkend="pk-package-sack-sort-summary">pk_package_sack_sort_summary</link>        (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="gboolean">gboolean</link>            <link linkend="pk-package-sack-add-package">pk_package_sack_add_package</link>         (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="PkPackage">PkPackage</link> *package);
<link linkend="gboolean">gboolean</link>            <link linkend="pk-package-sack-add-package-by-id">pk_package_sack_add_package_by_id</link>   (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         const <link linkend="gchar">gchar</link> *package_id,
                                                         <link linkend="GError">GError</link> **error);
<link linkend="gboolean">gboolean</link>            <link linkend="pk-package-sack-remove-package">pk_package_sack_remove_package</link>      (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="PkPackage">PkPackage</link> *package);
<link linkend="gboolean">gboolean</link>            <link linkend="pk-package-sack-remove-package-by-id">pk_package_sack_remove_package_by_id</link>
                                                        (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         const <link linkend="gchar">gchar</link> *package_id);
<link linkend="PkPackage">PkPackage</link> *         <link linkend="pk-package-sack-find-by-id">pk_package_sack_find_by_id</link>          (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         const <link linkend="gchar">gchar</link> *package_id);
<link linkend="guint64">guint64</link>             <link linkend="pk-package-sack-get-total-bytes">pk_package_sack_get_total_bytes</link>     (<link linkend="PkPackageSack">PkPackageSack</link> *sack);
<link linkend="gboolean">gboolean</link>            <link linkend="pk-package-sack-merge-generic-finish">pk_package_sack_merge_generic_finish</link>
                                                        (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GAsyncResult">GAsyncResult</link> *res,
                                                         <link linkend="GError">GError</link> **error);
<link linkend="void">void</link>                <link linkend="pk-package-sack-merge-resolve-async">pk_package_sack_merge_resolve_async</link> (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GCancellable">GCancellable</link> *cancellable,
                                                         <link linkend="PkProgressCallback">PkProgressCallback</link> progress_callback,
                                                         <link linkend="gpointer">gpointer</link> progress_user_data,
                                                         <link linkend="GAsyncReadyCallback">GAsyncReadyCallback</link> callback,
                                                         <link linkend="gpointer">gpointer</link> user_data);
<link linkend="void">void</link>                <link linkend="pk-package-sack-merge-details-async">pk_package_sack_merge_details_async</link> (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GCancellable">GCancellable</link> *cancellable,
                                                         <link linkend="PkProgressCallback">PkProgressCallback</link> progress_callback,
                                                         <link linkend="gpointer">gpointer</link> progress_user_data,
                                                         <link linkend="GAsyncReadyCallback">GAsyncReadyCallback</link> callback,
                                                         <link linkend="gpointer">gpointer</link> user_data);
<link linkend="void">void</link>                <link linkend="pk-package-sack-merge-update-detail-async">pk_package_sack_merge_update_detail_async</link>
                                                        (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GCancellable">GCancellable</link> *cancellable,
                                                         <link linkend="PkProgressCallback">PkProgressCallback</link> progress_callback,
                                                         <link linkend="gpointer">gpointer</link> progress_user_data,
                                                         <link linkend="GAsyncReadyCallback">GAsyncReadyCallback</link> callback,
                                                         <link linkend="gpointer">gpointer</link> user_data);
</synopsis>
</refsynopsisdiv>

<refsect1 id="PkPackageSack.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<synopsis>
  <link linkend="GObject">GObject</link>
   +----PkPackageSack
</synopsis>
</refsect1>








<refsect1 id="PkPackageSack.description" role="desc">
<title role="desc.title">Description</title>
<para>
A package sack is a set of packages that can have operations done on them
in parallel. This might be adding summary text for bare package ID's, or
to add package or update details.</para>
<para>
</para>
</refsect1>

<refsect1 id="PkPackageSack.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="PK-PACKAGE-SACK-ERROR--CAPS" role="macro">
<title>PK_PACKAGE_SACK_ERROR</title>
<indexterm zone="PK-PACKAGE-SACK-ERROR--CAPS"><primary sortas="PK_PACKAGE_SACK_ERROR">PK_PACKAGE_SACK_ERROR</primary></indexterm><programlisting>#define PK_PACKAGE_SACK_ERROR		(pk_package_sack_error_quark ())
</programlisting>
<para>
</para></refsect2>
<refsect2 id="PK-PACKAGE-SACK-TYPE-ERROR--CAPS" role="macro">
<title>PK_PACKAGE_SACK_TYPE_ERROR</title>
<indexterm zone="PK-PACKAGE-SACK-TYPE-ERROR--CAPS"><primary sortas="PK_PACKAGE_SACK_TYPE_ERROR">PK_PACKAGE_SACK_TYPE_ERROR</primary></indexterm><programlisting>#define PK_PACKAGE_SACK_TYPE_ERROR	(pk_package_sack_error_get_type ())
</programlisting>
<para>
</para></refsect2>
<refsect2 id="PkPackageSackPrivate" role="struct">
<title>PkPackageSackPrivate</title>
<indexterm zone="PkPackageSackPrivate"><primary sortas="PkPackageSackPrivate">PkPackageSackPrivate</primary></indexterm><programlisting>typedef struct _PkPackageSackPrivate PkPackageSackPrivate;</programlisting>
<para>
Private <link linkend="PkPackageSack"><type>PkPackageSack</type></link> data</para>
<para>
</para></refsect2>
<refsect2 id="PkPackageSackResults" role="struct">
<title>PkPackageSackResults</title>
<indexterm zone="PkPackageSackResults"><primary sortas="PkPackageSackResults">PkPackageSackResults</primary></indexterm><programlisting>typedef struct _PkPackageSackResults PkPackageSackResults;</programlisting>
<para>
</para></refsect2>
<refsect2 id="PkPackageSack-struct" role="struct">
<title>PkPackageSack</title>
<indexterm zone="PkPackageSack-struct"><primary sortas="PkPackageSack">PkPackageSack</primary></indexterm><programlisting>typedef struct _PkPackageSack PkPackageSack;</programlisting>
<para>
</para></refsect2>
<refsect2 id="pk-package-sack-error-quark" role="function">
<title>pk_package_sack_error_quark ()</title>
<indexterm zone="pk-package-sack-error-quark"><primary sortas="pk_package_sack_error_quark">pk_package_sack_error_quark</primary></indexterm><programlisting><link linkend="GQuark">GQuark</link>              pk_package_sack_error_quark         (void);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-new" role="function">
<title>pk_package_sack_new ()</title>
<indexterm zone="pk-package-sack-new"><primary sortas="pk_package_sack_new">pk_package_sack_new</primary></indexterm><programlisting><link linkend="PkPackageSack">PkPackageSack</link> *     pk_package_sack_new                 (void);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a new PkPackageSack object.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-test" role="function">
<title>pk_package_sack_test ()</title>
<indexterm zone="pk-package-sack-test"><primary sortas="pk_package_sack_test">pk_package_sack_test</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_test                (<link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>user_data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-get-size" role="function">
<title>pk_package_sack_get_size ()</title>
<indexterm zone="pk-package-sack-get-size"><primary sortas="pk_package_sack_get_size">pk_package_sack_get_size</primary></indexterm><programlisting><link linkend="guint">guint</link>               pk_package_sack_get_size            (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Gets the number of packages in the sack</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the number of packages in the sack
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-get-index" role="function">
<title>pk_package_sack_get_index ()</title>
<indexterm zone="pk-package-sack-get-index"><primary sortas="pk_package_sack_get_index">pk_package_sack_get_index</primary></indexterm><programlisting><link linkend="PkPackage">PkPackage</link> *         pk_package_sack_get_index           (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="guint">guint</link> i);</programlisting>
<para>
Gets a packages from the sack</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>i</parameter>&#160;:</term>
<listitem><simpara> the instance to get
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a <link linkend="PkPackage"><literal>PkPackage</literal></link> instance
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-clear" role="function">
<title>pk_package_sack_clear ()</title>
<indexterm zone="pk-package-sack-clear"><primary sortas="pk_package_sack_clear">pk_package_sack_clear</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_clear               (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Empty all the packages from the sack</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-get-ids" role="function">
<title>pk_package_sack_get_ids ()</title>
<indexterm zone="pk-package-sack-get-ids"><primary sortas="pk_package_sack_get_ids">pk_package_sack_get_ids</primary></indexterm><programlisting><link linkend="gchar">gchar</link> **            pk_package_sack_get_ids             (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Returns all the Package IDs in the sack</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the number of packages in the sack, free with <link linkend="g-strfreev"><function>g_strfreev()</function></link>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-sort-package-id" role="function">
<title>pk_package_sack_sort_package_id ()</title>
<indexterm zone="pk-package-sack-sort-package-id"><primary sortas="pk_package_sack_sort_package_id">pk_package_sack_sort_package_id</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_sort_package_id     (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Sorts by Package ID</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-sort-info" role="function">
<title>pk_package_sack_sort_info ()</title>
<indexterm zone="pk-package-sack-sort-info"><primary sortas="pk_package_sack_sort_info">pk_package_sack_sort_info</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_sort_info           (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Sorts by PkInfoEnum</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-sort-summary" role="function">
<title>pk_package_sack_sort_summary ()</title>
<indexterm zone="pk-package-sack-sort-summary"><primary sortas="pk_package_sack_sort_summary">pk_package_sack_sort_summary</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_sort_summary        (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Sorts by summary</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-add-package" role="function">
<title>pk_package_sack_add_package ()</title>
<indexterm zone="pk-package-sack-add-package"><primary sortas="pk_package_sack_add_package">pk_package_sack_add_package</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pk_package_sack_add_package         (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="PkPackage">PkPackage</link> *package);</programlisting>
<para>
Adds a package to the sack.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>package</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackage"><type>PkPackage</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the package was added to the sack
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-add-package-by-id" role="function">
<title>pk_package_sack_add_package_by_id ()</title>
<indexterm zone="pk-package-sack-add-package-by-id"><primary sortas="pk_package_sack_add_package_by_id">pk_package_sack_add_package_by_id</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pk_package_sack_add_package_by_id   (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         const <link linkend="gchar">gchar</link> *package_id,
                                                         <link linkend="GError">GError</link> **error);</programlisting>
<para>
Adds a package reference to the sack.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>package_id</parameter>&#160;:</term>
<listitem><simpara> a package_id descriptor
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>error</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="GError"><literal>GError</literal></link> to put the error code and message in, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the package was added to the sack
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-remove-package" role="function">
<title>pk_package_sack_remove_package ()</title>
<indexterm zone="pk-package-sack-remove-package"><primary sortas="pk_package_sack_remove_package">pk_package_sack_remove_package</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pk_package_sack_remove_package      (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="PkPackage">PkPackage</link> *package);</programlisting>
<para>
Removes a package reference from the sack. The pointers have to match exactly.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>package</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackage"><type>PkPackage</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the package was removed from the sack
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-remove-package-by-id" role="function">
<title>pk_package_sack_remove_package_by_id ()</title>
<indexterm zone="pk-package-sack-remove-package-by-id"><primary sortas="pk_package_sack_remove_package_by_id">pk_package_sack_remove_package_by_id</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pk_package_sack_remove_package_by_id
                                                        (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         const <link linkend="gchar">gchar</link> *package_id);</programlisting>
<para>
Removes a package reference from the sack. As soon as one package is removed
the search is stopped.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>package_id</parameter>&#160;:</term>
<listitem><simpara> a package_id descriptor
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the package was removed from the sack
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-find-by-id" role="function">
<title>pk_package_sack_find_by_id ()</title>
<indexterm zone="pk-package-sack-find-by-id"><primary sortas="pk_package_sack_find_by_id">pk_package_sack_find_by_id</primary></indexterm><programlisting><link linkend="PkPackage">PkPackage</link> *         pk_package_sack_find_by_id          (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         const <link linkend="gchar">gchar</link> *package_id);</programlisting>
<para>
Finds a package in a sack from reference. As soon as one package is found
the search is stopped.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>package_id</parameter>&#160;:</term>
<listitem><simpara> a package_id descriptor
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the <link linkend="PkPackage"><type>PkPackage</type></link> object, or <link linkend="NULL--CAPS"><literal>NULL</literal></link> if unfound. Free with <link linkend="g-object-unref"><function>g_object_unref()</function></link>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-get-total-bytes" role="function">
<title>pk_package_sack_get_total_bytes ()</title>
<indexterm zone="pk-package-sack-get-total-bytes"><primary sortas="pk_package_sack_get_total_bytes">pk_package_sack_get_total_bytes</primary></indexterm><programlisting><link linkend="guint64">guint64</link>             pk_package_sack_get_total_bytes     (<link linkend="PkPackageSack">PkPackageSack</link> *sack);</programlisting>
<para>
Gets the total size of the package sack in bytes.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the size in bytes
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-merge-generic-finish" role="function">
<title>pk_package_sack_merge_generic_finish ()</title>
<indexterm zone="pk-package-sack-merge-generic-finish"><primary sortas="pk_package_sack_merge_generic_finish">pk_package_sack_merge_generic_finish</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pk_package_sack_merge_generic_finish
                                                        (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GAsyncResult">GAsyncResult</link> *res,
                                                         <link linkend="GError">GError</link> **error);</programlisting>
<para>
Gets the result from the asynchronous function.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>res</parameter>&#160;:</term>
<listitem><simpara> the <link linkend="GAsyncResult"><type>GAsyncResult</type></link>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>error</parameter>&#160;:</term>
<listitem><simpara> A <link linkend="GError"><type>GError</type></link> or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> for success
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-merge-resolve-async" role="function">
<title>pk_package_sack_merge_resolve_async ()</title>
<indexterm zone="pk-package-sack-merge-resolve-async"><primary sortas="pk_package_sack_merge_resolve_async">pk_package_sack_merge_resolve_async</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_merge_resolve_async (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GCancellable">GCancellable</link> *cancellable,
                                                         <link linkend="PkProgressCallback">PkProgressCallback</link> progress_callback,
                                                         <link linkend="gpointer">gpointer</link> progress_user_data,
                                                         <link linkend="GAsyncReadyCallback">GAsyncReadyCallback</link> callback,
                                                         <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>
Merges in details about packages using resolve.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>cancellable</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="GCancellable"><type>GCancellable</type></link> or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>progress_callback</parameter>&#160;:</term>
<listitem><simpara> the function to run when the progress changes
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>progress_user_data</parameter>&#160;:</term>
<listitem><simpara> data to pass to <parameter>progress_callback</parameter>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>callback</parameter>&#160;:</term>
<listitem><simpara> the function to run on completion
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>user_data</parameter>&#160;:</term>
<listitem><simpara> the data to pass to <parameter>callback</parameter>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-merge-details-async" role="function">
<title>pk_package_sack_merge_details_async ()</title>
<indexterm zone="pk-package-sack-merge-details-async"><primary sortas="pk_package_sack_merge_details_async">pk_package_sack_merge_details_async</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_merge_details_async (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GCancellable">GCancellable</link> *cancellable,
                                                         <link linkend="PkProgressCallback">PkProgressCallback</link> progress_callback,
                                                         <link linkend="gpointer">gpointer</link> progress_user_data,
                                                         <link linkend="GAsyncReadyCallback">GAsyncReadyCallback</link> callback,
                                                         <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>
Merges in details about packages.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>cancellable</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="GCancellable"><type>GCancellable</type></link> or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>progress_callback</parameter>&#160;:</term>
<listitem><simpara> the function to run when the progress changes
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>progress_user_data</parameter>&#160;:</term>
<listitem><simpara> data to pass to <parameter>progress_callback</parameter>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>callback</parameter>&#160;:</term>
<listitem><simpara> the function to run on completion
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>user_data</parameter>&#160;:</term>
<listitem><simpara> the data to pass to <parameter>callback</parameter>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="pk-package-sack-merge-update-detail-async" role="function">
<title>pk_package_sack_merge_update_detail_async ()</title>
<indexterm zone="pk-package-sack-merge-update-detail-async"><primary sortas="pk_package_sack_merge_update_detail_async">pk_package_sack_merge_update_detail_async</primary></indexterm><programlisting><link linkend="void">void</link>                pk_package_sack_merge_update_detail_async
                                                        (<link linkend="PkPackageSack">PkPackageSack</link> *sack,
                                                         <link linkend="GCancellable">GCancellable</link> *cancellable,
                                                         <link linkend="PkProgressCallback">PkProgressCallback</link> progress_callback,
                                                         <link linkend="gpointer">gpointer</link> progress_user_data,
                                                         <link linkend="GAsyncReadyCallback">GAsyncReadyCallback</link> callback,
                                                         <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>
Merges in update details about packages.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>sack</parameter>&#160;:</term>
<listitem><simpara> a valid <link linkend="PkPackageSack"><type>PkPackageSack</type></link> instance
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>cancellable</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="GCancellable"><type>GCancellable</type></link> or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>progress_callback</parameter>&#160;:</term>
<listitem><simpara> the function to run when the progress changes
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>progress_user_data</parameter>&#160;:</term>
<listitem><simpara> data to pass to <parameter>progress_callback</parameter>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>callback</parameter>&#160;:</term>
<listitem><simpara> the function to run on completion
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>user_data</parameter>&#160;:</term>
<listitem><simpara> the data to pass to <parameter>callback</parameter>
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
