![]() |
![]() |
![]() |
ZIF Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
GPtrArray * zif_store_array_new (void
); gboolean zif_store_array_add_store (GPtrArray *store_array
,ZifStore *store
); gboolean zif_store_array_add_stores (GPtrArray *store_array
,GPtrArray *stores
); gboolean zif_store_array_add_local (GPtrArray *store_array
,ZifState *state
,GError **error
); gboolean zif_store_array_add_remote (GPtrArray *store_array
,ZifState *state
,GError **error
); gboolean zif_store_array_add_remote_enabled (GPtrArray *store_array
,ZifState *state
,GError **error
); gboolean zif_store_array_clean (GPtrArray *store_array
,ZifState *state
,GError **error
); gboolean zif_store_array_refresh (GPtrArray *store_array
,gboolean force
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_resolve (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_search_name (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_search_details (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_search_group (GPtrArray *store_array
,gchar **group_enum
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_search_category (GPtrArray *store_array
,gchar **group_id
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_search_file (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_what_provides (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_get_packages (GPtrArray *store_array
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_get_updates (GPtrArray *store_array
,GPtrArray *packages
,ZifState *state
,GError **error
); ZifPackage * zif_store_array_find_package (GPtrArray *store_array
,const gchar *package_id
,ZifState *state
,GError **error
); GPtrArray * zif_store_array_get_categories (GPtrArray *store_array
,ZifState *state
,GError **error
);
A GPtrArray is the container where ZifStore's are kept. Global operations can be done on the array and not the indervidual stores.
IMPORTANT: any errors that happen on the ZifStores are fatal unless you're
using zif_state_set_error_handler()
.
GPtrArray * zif_store_array_new (void
);
Returns : |
A new GPtrArray class instance. |
Since 0.1.0
gboolean zif_store_array_add_store (GPtrArray *store_array
,ZifStore *store
);
Add a single ZifStore to the GPtrArray.
|
the GPtrArray of ZifStores |
|
the ZifStore to add |
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
gboolean zif_store_array_add_stores (GPtrArray *store_array
,GPtrArray *stores
);
Add an array of ZifStore's to the GPtrArray.
|
the GPtrArray of ZifStores |
|
the array of ZifStore's to add |
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
gboolean zif_store_array_add_local (GPtrArray *store_array
,ZifState *state
,GError **error
);
Convenience function to add local store to the GPtrArray.
|
the GPtrArray of ZifStores |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
gboolean zif_store_array_add_remote (GPtrArray *store_array
,ZifState *state
,GError **error
);
Convenience function to add remote stores to the GPtrArray.
|
the GPtrArray of ZifStores |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
gboolean zif_store_array_add_remote_enabled (GPtrArray *store_array
,ZifState *state
,GError **error
);
Convenience function to add enabled remote stores to the GPtrArray.
|
the GPtrArray of ZifStores |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
gboolean zif_store_array_clean (GPtrArray *store_array
,ZifState *state
,GError **error
);
Cleans the ZifStoreRemote objects by deleting cache.
|
the GPtrArray of ZifStores |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
gboolean zif_store_array_refresh (GPtrArray *store_array
,gboolean force
,ZifState *state
,GError **error
);
Refreshs the ZifStoreRemote objects by downloading new data
|
the GPtrArray of ZifStores |
|
if the data should be re-downloaded if it's still valid |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
TRUE for success, FALSE for failure
|
Since 0.1.0
GPtrArray * zif_store_array_resolve (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
);
Finds packages matching the package name exactly.
|
the GPtrArray of ZifStores |
|
the search term, e.g. "gnome-power-manager" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_search_name (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
);
Find packages that match the package name in some part.
|
the GPtrArray of ZifStores |
|
the search term, e.g. "power" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_search_details (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
);
Find packages that match some detail about the package.
|
the GPtrArray of ZifStores |
|
the search term, e.g. "trouble" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_search_group (GPtrArray *store_array
,gchar **group_enum
,ZifState *state
,GError **error
);
Find packages that belong in a specific group.
|
the GPtrArray of ZifStores |
|
the group enumerated value, e.g. "games" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_search_category (GPtrArray *store_array
,gchar **group_id
,ZifState *state
,GError **error
);
Find packages that belong in a specific category.
|
the GPtrArray of ZifStores |
|
the group id, e.g. "gnome-system-tools" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_search_file (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
);
Find packages that provide the specified file.
|
the GPtrArray of ZifStores |
|
the search term, e.g. "/usr/bin/gnome-power-manager" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_what_provides (GPtrArray *store_array
,gchar **search
,ZifState *state
,GError **error
);
Find packages that provide a specific string.
|
the GPtrArray of ZifStores |
|
the search term, e.g. "gstreamer(codec-mp3)" |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_get_packages (GPtrArray *store_array
,ZifState *state
,GError **error
);
Return all packages in the GPtrArray's.
|
the GPtrArray of ZifStores |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
GPtrArray * zif_store_array_get_updates (GPtrArray *store_array
,GPtrArray *packages
,ZifState *state
,GError **error
);
Return a list of packages that are updatable.
|
the GPtrArray of ZifStores |
|
the GPtrArray of ZifPackages to check for updates |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifPackage's |
Since 0.1.0
ZifPackage * zif_store_array_find_package (GPtrArray *store_array
,const gchar *package_id
,ZifState *state
,GError **error
);
Find a single package in the GPtrArray.
|
the GPtrArray of ZifStores |
|
the PackageId which defines the package |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
A single ZifPackage or NULL
|
Since 0.1.0
GPtrArray * zif_store_array_get_categories (GPtrArray *store_array
,ZifState *state
,GError **error
);
Return a list of custom categories from all repos.
|
the GPtrArray of ZifStores |
|
a ZifState to use for progress reporting |
|
a GError which is used on failure, or NULL
|
Returns : |
an array of ZifCategory's |
Since 0.1.0