Method
SnapdClientget_snaps_sync
since: 1.42
Declaration [src]
GPtrArray*
snapd_client_get_snaps_sync (
SnapdClient* client,
SnapdGetSnapsFlags flags,
GStrv names,
GCancellable* cancellable,
GError** error
)
Description [src]
Get information on installed snaps (snaps with status
SNAPD_SNAP_STATUS_ACTIVE). If flags contains
SNAPD_GET_SNAPS_FLAGS_INCLUDE_INACTIVE then also return snaps with status
SNAPD_SNAP_STATUS_INSTALLED.
If flags contains SNAPD_GET_SNAPS_FLAGS_REFRESH_INHIBITED, then it will
return only those snaps that are inhibited from being refreshed, for example
due to having a running instace.
If names is not NULL and contains at least one name only snaps that match
these names are returned. If a snap is not installed it is not returned (no
error is generated).
Available since: 1.42
Parameters
flags-
Type:
SnapdGetSnapsFlagsA set of
SnapdGetSnapsFlagsto control what results are returned. names-
Type: An array of
utf8A list of snap names or
NULL.The argument can be NULL.The array must be NULL-terminated.Each element is a NUL terminated UTF-8 string. cancellable-
Type:
GCancellableA
GCancellableorNULL.The argument can be NULL.The data is owned by the caller of the method. error-
Type:
GError **The return location for a recoverable error.
The argument can be NULL.If the return location is not NULL, then you must initialize it to aNULLGError*.The argument will be left initialized to NULLby the method if there are no errors.In case of error, the argument will be set to a newly allocated GError; the caller will take ownership of the data, and be responsible for freeing it.