![]() |
![]() |
![]() |
Disk Utility Library Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Signals |
GduPoolClass; GduPoolPrivate; GduPool; GduPool * gdu_pool_new (void
); GduPool * gdu_pool_new_for_address (const gchar *ssh_user_name
,const gchar *ssh_address
,GError **error
); const gchar * gdu_pool_get_ssh_user_name (GduPool *pool
); const gchar * gdu_pool_get_ssh_address (GduPool *pool
); char * gdu_pool_get_daemon_version (GduPool *pool
); gboolean gdu_pool_is_daemon_inhibited (GduPool *pool
); gboolean gdu_pool_supports_luks_devices (GduPool *pool
); GList * gdu_pool_get_known_filesystems (GduPool *pool
); GduKnownFilesystem * gdu_pool_get_known_filesystem_by_id (GduPool *pool
,const char *id
); GduDevice * gdu_pool_get_by_object_path (GduPool *pool
,const char *object_path
); GduDevice * gdu_pool_get_by_device_file (GduPool *pool
,const char *device_file
); GduPresentable * gdu_pool_get_volume_by_device (GduPool *pool
,GduDevice *device
); GduPresentable * gdu_pool_get_drive_by_device (GduPool *pool
,GduDevice *device
); GduLinuxMdDrive * gdu_pool_get_linux_md_drive_by_uuid (GduPool *pool
,const gchar *uuid
); GduPresentable * gdu_pool_get_presentable_by_id (GduPool *pool
,const gchar *id
); gboolean gdu_pool_has_presentable (GduPool *pool
,GduPresentable *presentable
); GList * gdu_pool_get_devices (GduPool *pool
); GList * gdu_pool_get_presentables (GduPool *pool
); GList * gdu_pool_get_enclosed_presentables (GduPool *pool
,GduPresentable *presentable
); GduAdapter * gdu_pool_get_adapter_by_object_path (GduPool *pool
,const char *object_path
); GList * gdu_pool_get_adapters (GduPool *pool
); GduExpander * gdu_pool_get_expander_by_object_path (GduPool *pool
,const char *object_path
); GList * gdu_pool_get_expanders (GduPool *pool
); GduPort * gdu_pool_get_port_by_object_path (GduPool *pool
,const char *object_path
); GList * gdu_pool_get_ports (GduPool *pool
); GduPresentable * gdu_pool_get_hub_by_object_path (GduPool *pool
,const gchar *object_path
); void gdu_pool_op_linux_md_start (GduPool *pool
,GPtrArray *component_objpaths
,GduPoolLinuxMdStartCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_md_create (GduPool *pool
,GPtrArray *component_objpaths
,const gchar *level
,guint64 stripe_size
,const gchar *name
,GduPoolLinuxMdCreateCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_vg_start (GduPool *pool
,const gchar *uuid
,GduPoolLinuxLvm2VGStartCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_vg_stop (GduPool *pool
,const gchar *uuid
,GduPoolLinuxLvm2VGStopCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_lv_start (GduPool *pool
,const gchar *group_uuid
,const gchar *uuid
,GduPoolLinuxLvm2VGStartCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_vg_set_name (GduPool *pool
,const gchar *uuid
,const gchar *new_name
,GduPoolLinuxLvm2VGSetNameCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_lv_set_name (GduPool *pool
,const gchar *group_uuid
,const gchar *uuid
,const gchar *new_name
,GduPoolLinuxLvm2LVSetNameCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_lv_remove (GduPool *pool
,const gchar *group_uuid
,const gchar *uuid
,GduPoolLinuxLvm2LVRemoveCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_lv_create (GduPool *pool
,const gchar *group_uuid
,const gchar *name
,guint64 size
,guint num_stripes
,guint64 stripe_size
,guint num_mirrors
,const char *fstype
,const char *fslabel
,const char *encrypt_passphrase
,gboolean fs_take_ownership
,GduPoolLinuxLvm2LVCreateCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_vg_add_pv (GduPool *pool
,const gchar *uuid
,const gchar *physical_volume_object_path
,GduPoolLinuxLvm2VGAddPVCompletedFunc callback
,gpointer user_data
); void gdu_pool_op_linux_lvm2_vg_remove_pv (GduPool *pool
,const gchar *vg_uuid
,const gchar *pv_uuid
,GduPoolLinuxLvm2VGRemovePVCompletedFunc callback
,gpointer user_data
);
"adapter-added" : Run Last "adapter-changed" : Run Last "adapter-removed" : Run Last "device-added" : Run Last "device-changed" : Run Last "device-job-changed" : Run Last "device-removed" : Run Last "disconnected" : Run Last "expander-added" : Run Last "expander-changed" : Run Last "expander-removed" : Run Last "port-added" : Run Last "port-changed" : Run Last "port-removed" : Run Last "presentable-added" : Run Last "presentable-changed" : Run Last "presentable-job-changed" : Run Last "presentable-removed" : Run Last
typedef struct { GObjectClass parent_class; /* signals */ void (*disconnected) (GduPool *pool); void (*device_added) (GduPool *pool, GduDevice *device); void (*device_removed) (GduPool *pool, GduDevice *device); void (*device_changed) (GduPool *pool, GduDevice *device); void (*device_job_changed) (GduPool *pool, GduDevice *device); void (*adapter_added) (GduPool *pool, GduAdapter *adapter); void (*adapter_removed) (GduPool *pool, GduAdapter *adapter); void (*adapter_changed) (GduPool *pool, GduAdapter *adapter); void (*expander_added) (GduPool *pool, GduExpander *expander); void (*expander_removed) (GduPool *pool, GduExpander *expander); void (*expander_changed) (GduPool *pool, GduExpander *expander); void (*port_added) (GduPool *pool, GduPort *port); void (*port_removed) (GduPool *pool, GduPort *port); void (*port_changed) (GduPool *pool, GduPort *port); void (*presentable_added) (GduPool *pool, GduPresentable *presentable); void (*presentable_removed) (GduPool *pool, GduPresentable *presentable); void (*presentable_changed) (GduPool *pool, GduPresentable *presentable); void (*presentable_job_changed) (GduPool *pool, GduPresentable *presentable); } GduPoolClass;
GduPool * gdu_pool_new (void
);
Create a new GduPool object.
Returns : |
A GduPool object. Caller must free this object using g_object_unref() .
|
GduPool * gdu_pool_new_for_address (const gchar *ssh_user_name
,const gchar *ssh_address
,GError **error
);
|
|
|
|
|
|
Returns : |
const gchar * gdu_pool_get_ssh_user_name (GduPool *pool
);
|
|
Returns : |
const gchar * gdu_pool_get_ssh_address (GduPool *pool
);
|
|
Returns : |
char * gdu_pool_get_daemon_version (GduPool *pool
);
Get the version of the udisks on the system.
gboolean gdu_pool_is_daemon_inhibited (GduPool *pool
);
Checks if the daemon is currently inhibited.
gboolean gdu_pool_supports_luks_devices (GduPool *pool
);
Determine if the udisks daemon supports LUKS encrypted devices.
GList * gdu_pool_get_known_filesystems (GduPool *pool
);
Get a list of file systems known to the udisks daemon.
|
A GduPool. |
Returns : |
A GList of GduKnownFilesystem objects. Caller must free
this (unref all objects, then use g_list_free() ).
|
GduKnownFilesystem * gdu_pool_get_known_filesystem_by_id (GduPool *pool
,const char *id
);
Looks up a known file system by id.
|
A GduPool. |
|
Identifier for the file system, e.g. ext3 or vfat .
|
Returns : |
A GduKnownFilesystem object or NULL if file system
corresponding to id exists. Caller must free this object using
g_object_unref() .
|
GduDevice * gdu_pool_get_by_object_path (GduPool *pool
,const char *object_path
);
Looks up GduPort object for object_path
.
|
the pool |
|
the D-Bus object path |
Returns : |
A GduPort object for object_path , otherwise
NULL. Caller must unref this object using g_object_unref() .
|
GduDevice * gdu_pool_get_by_device_file (GduPool *pool
,const char *device_file
);
Looks up GduDevice object for device_file
.
|
the device pool |
|
the UNIX block special device file, e.g. /dev/sda1. |
Returns : |
A GduDevice object for object_path , otherwise
NULL. Caller must unref this object using g_object_unref() .
|
GduPresentable * gdu_pool_get_volume_by_device (GduPool *pool
,GduDevice *device
);
Given device
, find the GduVolume object for it.
|
A GduPool. |
|
A GduDevice. |
Returns : |
A GduVolume object or NULL if no device isn't a
volume. Caller must free this object with g_object_unref() .
|
GduPresentable * gdu_pool_get_drive_by_device (GduPool *pool
,GduDevice *device
);
Given device
, find the GduDrive object for it.
|
A GduPool. |
|
A GduDevice. |
Returns : |
A GduDrive object or NULL if no device isn't a
drive. Caller must free this object with g_object_unref() .
|
GduLinuxMdDrive * gdu_pool_get_linux_md_drive_by_uuid (GduPool *pool
,const gchar *uuid
);
|
|
|
|
Returns : |
GduPresentable * gdu_pool_get_presentable_by_id (GduPool *pool
,const gchar *id
);
|
|
|
|
Returns : |
gboolean gdu_pool_has_presentable (GduPool *pool
,GduPresentable *presentable
);
|
|
|
|
Returns : |
GList * gdu_pool_get_devices (GduPool *pool
);
Get a list of all devices. The returned list is topologically sorted, e.g. for any device A with a dependency on a device B, A is guaranteed to appear after B.
|
A GduPool. |
Returns : |
A GList of GduDevice objects. Caller must free this
(unref all objects, then use g_list_free() ).
|
GList * gdu_pool_get_presentables (GduPool *pool
);
Get a list of all presentables.
|
A GduPool |
Returns : |
A GList of objects implementing the GduPresentable
interface. Caller must free this (unref all objects, then use
g_list_free() ).
|
GList * gdu_pool_get_enclosed_presentables (GduPool *pool
,GduPresentable *presentable
);
|
|
|
|
Returns : |
GduAdapter * gdu_pool_get_adapter_by_object_path (GduPool *pool
,const char *object_path
);
Looks up GduAdapter object for object_path
.
|
the pool |
|
the D-Bus object path |
Returns : |
A GduAdapter object for object_path , otherwise
NULL. Caller must unref this object using g_object_unref() .
|
GList * gdu_pool_get_adapters (GduPool *pool
);
Get a list of all adapters.
|
A GduPool. |
Returns : |
A GList of GduAdapter objects. Caller must free this
(unref all objects, then use g_list_free() ).
|
GduExpander * gdu_pool_get_expander_by_object_path (GduPool *pool
,const char *object_path
);
Looks up GduExpander object for object_path
.
|
the pool |
|
the D-Bus object path |
Returns : |
A GduExpander object for object_path , otherwise
NULL. Caller must unref this object using g_object_unref() .
|
GList * gdu_pool_get_expanders (GduPool *pool
);
Get a list of all expanders.
|
A GduPool. |
Returns : |
A GList of GduExpander objects. Caller must free this
(unref all objects, then use g_list_free() ).
|
GduPort * gdu_pool_get_port_by_object_path (GduPool *pool
,const char *object_path
);
|
|
|
|
Returns : |
GList * gdu_pool_get_ports (GduPool *pool
);
Get a list of all ports.
|
A GduPool. |
Returns : |
A GList of GduPort objects. Caller must free this
(unref all objects, then use g_list_free() ).
|
GduPresentable * gdu_pool_get_hub_by_object_path (GduPool *pool
,const gchar *object_path
);
|
|
|
|
Returns : |
void gdu_pool_op_linux_md_start (GduPool *pool
,GPtrArray *component_objpaths
,GduPoolLinuxMdStartCompletedFunc callback
,gpointer user_data
);
Starts a Linux md Software Array.
void gdu_pool_op_linux_md_create (GduPool *pool
,GPtrArray *component_objpaths
,const gchar *level
,guint64 stripe_size
,const gchar *name
,GduPoolLinuxMdCreateCompletedFunc callback
,gpointer user_data
);
Creates a Linux md Software Array.
void gdu_pool_op_linux_lvm2_vg_start (GduPool *pool
,const gchar *uuid
,GduPoolLinuxLvm2VGStartCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_vg_stop (GduPool *pool
,const gchar *uuid
,GduPoolLinuxLvm2VGStopCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_lv_start (GduPool *pool
,const gchar *group_uuid
,const gchar *uuid
,GduPoolLinuxLvm2VGStartCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_vg_set_name (GduPool *pool
,const gchar *uuid
,const gchar *new_name
,GduPoolLinuxLvm2VGSetNameCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_lv_set_name (GduPool *pool
,const gchar *group_uuid
,const gchar *uuid
,const gchar *new_name
,GduPoolLinuxLvm2LVSetNameCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_lv_remove (GduPool *pool
,const gchar *group_uuid
,const gchar *uuid
,GduPoolLinuxLvm2LVRemoveCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_lv_create (GduPool *pool
,const gchar *group_uuid
,const gchar *name
,guint64 size
,guint num_stripes
,guint64 stripe_size
,guint num_mirrors
,const char *fstype
,const char *fslabel
,const char *encrypt_passphrase
,gboolean fs_take_ownership
,GduPoolLinuxLvm2LVCreateCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_vg_add_pv (GduPool *pool
,const gchar *uuid
,const gchar *physical_volume_object_path
,GduPoolLinuxLvm2VGAddPVCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
void gdu_pool_op_linux_lvm2_vg_remove_pv (GduPool *pool
,const gchar *vg_uuid
,const gchar *pv_uuid
,GduPoolLinuxLvm2VGRemovePVCompletedFunc callback
,gpointer user_data
);
|
|
|
|
|
|
|
|
|
"adapter-added"
signalvoid user_function (GduPool *pool, GduAdapter *adapter, gpointer user_data) : Run Last
Emitted when adapter
is added to pool
.
@: @:
|
The GduPool emitting the signal. |
|
The GduAdapter that was added. |
|
user data set when the signal handler was connected. |
"adapter-changed"
signalvoid user_function (GduPool *pool, GduAdapter *adapter, gpointer user_data) : Run Last
Emitted when adapter
is changed.
@: @:
|
The GduPool emitting the signal. |
|
A GduAdapter. |
|
user data set when the signal handler was connected. |
"adapter-removed"
signalvoid user_function (GduPool *pool, GduAdapter *adapter, gpointer user_data) : Run Last
Emitted when adapter
is removed from pool
. Recipients
should release references to adapter
.
@: @:
|
The GduPool emitting the signal. |
|
The GduAdapter that was removed. |
|
user data set when the signal handler was connected. |
"device-added"
signalvoid user_function (GduPool *pool, GduDevice *device, gpointer user_data) : Run Last
Emitted when device
is added to pool
.
@: @:
"device-changed"
signalvoid user_function (GduPool *pool, GduDevice *device, gpointer user_data) : Run Last
Emitted when device
is changed.
@: @:
"device-job-changed"
signalvoid user_function (GduPool *pool, GduDevice *device, gpointer user_data) : Run Last
Emitted when job status on device
changes.
@: @:
"device-removed"
signalvoid user_function (GduPool *pool, GduDevice *device, gpointer user_data) : Run Last
Emitted when device
is removed from pool
. Recipients
should release references to device
.
@: @:
"disconnected"
signalvoid user_function (GduPool *pool, gpointer user_data) : Run Last
Emitted when the underlying connection has been disconnected.
If you hold a reference to pool
, now is a good time to give it up.
@:
|
The GduPool emitting the signal. |
|
user data set when the signal handler was connected. |
"expander-added"
signalvoid user_function (GduPool *pool, GduExpander *expander, gpointer user_data) : Run Last
Emitted when expander
is added to pool
.
@: @:
|
The GduPool emitting the signal. |
|
The GduExpander that was added. |
|
user data set when the signal handler was connected. |
"expander-changed"
signalvoid user_function (GduPool *pool, GduExpander *expander, gpointer user_data) : Run Last
Emitted when expander
is changed.
@: @:
|
The GduPool emitting the signal. |
|
A GduExpander. |
|
user data set when the signal handler was connected. |
"expander-removed"
signalvoid user_function (GduPool *pool, GduExpander *expander, gpointer user_data) : Run Last
Emitted when expander
is removed from pool
. Recipients
should release references to expander
.
@: @:
|
The GduPool emitting the signal. |
|
The GduExpander that was removed. |
|
user data set when the signal handler was connected. |
"port-added"
signalvoid user_function (GduPool *pool, GduPort *port, gpointer user_data) : Run Last
Emitted when port
is added to pool
.
@: @:
|
The GduPool emitting the signal. |
|
The GduPort that was added. |
|
user data set when the signal handler was connected. |
"port-changed"
signalvoid user_function (GduPool *pool, GduPort *port, gpointer user_data) : Run Last
Emitted when port
is changed.
@: @:
|
The GduPool emitting the signal. |
|
A GduPort. |
|
user data set when the signal handler was connected. |
"port-removed"
signalvoid user_function (GduPool *pool, GduPort *port, gpointer user_data) : Run Last
Emitted when port
is removed from pool
. Recipients
should release references to port
.
@: @:
|
The GduPool emitting the signal. |
|
The GduPort that was removed. |
|
user data set when the signal handler was connected. |
"presentable-added"
signalvoid user_function (GduPool *pool, GduPresentable *presentable, gpointer user_data) : Run Last
Emitted when presentable
is added to pool
.
@: @:
|
The GduPool emitting the signal. |
|
The GduPresentable that was added. |
|
user data set when the signal handler was connected. |
"presentable-changed"
signalvoid user_function (GduPool *pool, GduPresentable *presentable, gpointer user_data) : Run Last
Emitted when presentable
changes.
@: @:
|
The GduPool emitting the signal. |
|
A GduPresentable. |
|
user data set when the signal handler was connected. |
"presentable-job-changed"
signalvoid user_function (GduPool *pool, GduPresentable *presentable, gpointer user_data) : Run Last
Emitted when job status on presentable
changes.
@: @:
|
The GduPool emitting the signal. |
|
A GduPresentable. |
|
user data set when the signal handler was connected. |
"presentable-removed"
signalvoid user_function (GduPool *pool, GduPresentable *presentable, gpointer user_data) : Run Last
Emitted when presentable
is removed from pool
. Recipients
should release references to presentable
.
@: @:
|
The GduPool emitting the signal. |
|
The GduPresentable that was removed. |
|
user data set when the signal handler was connected. |