## GnomeVFSDrive GnomeVFSDrive — Container for GnomeVFSVolume (floppy drive, CD reader, ...) |

## Synopsis

    enum        GnomeVFSDeviceType;
                GnomeVFSDrive;
                GnomeVFSDriveClass;
    #define     GNOME_IS_VFS_DRIVE              (o)
    #define     GNOME_IS_VFS_DRIVE_CLASS        (k)
    #define     GNOME_VFS_TYPE_DRIVE
    #define     GNOME_VFS_DRIVE                 (o)
    #define     GNOME_VFS_DRIVE_CLASS           (k)
    gint        gnome_vfs_drive_compare         (GnomeVFSDrive *a,
                                                 GnomeVFSDrive *b);
    void        gnome_vfs_drive_eject           (GnomeVFSDrive *drive,
                                                 GnomeVFSVolumeOpCallback callback,
                                                 gpointer user_data);
    char*       gnome_vfs_drive_get_activation_uri
                                                (GnomeVFSDrive *drive);
    char*       gnome_vfs_drive_get_device_path (GnomeVFSDrive *drive);
    GnomeVFSDeviceType gnome_vfs_drive_get_device_type
                                                (GnomeVFSDrive *drive);
    char*       gnome_vfs_drive_get_display_name
                                                (GnomeVFSDrive *drive);
    char*       gnome_vfs_drive_get_hal_udi     (GnomeVFSDrive *drive);
    char*       gnome_vfs_drive_get_icon        (GnomeVFSDrive *drive);
    gulong      gnome_vfs_drive_get_id          (GnomeVFSDrive *drive);
    GnomeVFSVolume* gnome_vfs_drive_get_mounted_volume
                                                (GnomeVFSDrive *drive);
    GList*      gnome_vfs_drive_get_mounted_volumes
                                                (GnomeVFSDrive *drive);
    void        gnome_vfs_drive_volume_list_free
                                                (GList *volumes);
    GType       gnome_vfs_drive_get_type        (void);
    gboolean    gnome_vfs_drive_is_connected    (GnomeVFSDrive *drive);
    gboolean    gnome_vfs_drive_is_mounted      (GnomeVFSDrive *drive);
    gboolean    gnome_vfs_drive_is_user_visible (GnomeVFSDrive *drive);
    void        gnome_vfs_drive_mount           (GnomeVFSDrive *drive,
                                                 GnomeVFSVolumeOpCallback callback,
                                                 gpointer user_data);
    GnomeVFSDrive* gnome_vfs_drive_ref          (GnomeVFSDrive *drive);
    void        gnome_vfs_drive_unmount         (GnomeVFSDrive *drive,
                                                 GnomeVFSVolumeOpCallback callback,
                                                 gpointer user_data);
    void        gnome_vfs_drive_unref           (GnomeVFSDrive *drive);

## Object Hierarchy

      GObject
       +----GnomeVFSDrive

## Signal Prototypes

    "volume-mounted"
                void        user_function      (GnomeVFSDrive *vfsdrive,
                                                GnomeVFSVolume *arg1,
                                                gpointer user_data);
    "volume-pre-unmount"
                void        user_function      (GnomeVFSDrive *vfsdrive,
                                                GnomeVFSVolume *arg1,
                                                gpointer user_data);
    "volume-unmounted"
                void        user_function      (GnomeVFSDrive *vfsdrive,
                                                GnomeVFSVolume *arg1,
                                                gpointer user_data);

## Description

## Details

### enum GnomeVFSDeviceType

    typedef enum {
    	GNOME_VFS_DEVICE_TYPE_UNKNOWN,
    	GNOME_VFS_DEVICE_TYPE_AUDIO_CD,
    	GNOME_VFS_DEVICE_TYPE_VIDEO_DVD,
    	GNOME_VFS_DEVICE_TYPE_HARDDRIVE,
    	GNOME_VFS_DEVICE_TYPE_CDROM,
    	GNOME_VFS_DEVICE_TYPE_FLOPPY,
    	GNOME_VFS_DEVICE_TYPE_ZIP,
    	GNOME_VFS_DEVICE_TYPE_JAZ,
    	GNOME_VFS_DEVICE_TYPE_NFS,
    	GNOME_VFS_DEVICE_TYPE_AUTOFS,
    	GNOME_VFS_DEVICE_TYPE_CAMERA,
    	GNOME_VFS_DEVICE_TYPE_MEMORY_STICK,
    	GNOME_VFS_DEVICE_TYPE_SMB,
    	GNOME_VFS_DEVICE_TYPE_APPLE,
    	GNOME_VFS_DEVICE_TYPE_MUSIC_PLAYER,
    	GNOME_VFS_DEVICE_TYPE_WINDOWS,
    	GNOME_VFS_DEVICE_TYPE_LOOPBACK,
    	GNOME_VFS_DEVICE_TYPE_NETWORK
    } GnomeVFSDeviceType;

### GnomeVFSDrive

    typedef struct _GnomeVFSDrive GnomeVFSDrive;

`param` volume_monitor_daemon Handle to the volume monitor daemon `param` drive Handle to the GnomeVFSDrive object

### GnomeVFSDriveClass

    typedef struct {
    	GObjectClass parent_class;

    	void (* volume_mounted)	  	(GnomeVFSDrive *drive,
    				   	 GnomeVFSVolume	*volume);
    	void (* volume_pre_unmount)	(GnomeVFSDrive *drive,
    				   	 GnomeVFSVolume	*volume);
    	void (* volume_unmounted)	(GnomeVFSDrive *drive,
    				   	 GnomeVFSVolume	*volume);
    } GnomeVFSDriveClass;

### GNOME_IS_VFS_DRIVE()

    #define GNOME_IS_VFS_DRIVE(o)       (G_TYPE_CHECK_INSTANCE_TYPE ((o), GNOME_VFS_TYPE_DRIVE))

`o` : |

### GNOME_IS_VFS_DRIVE_CLASS()

    #define GNOME_IS_VFS_DRIVE_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), GNOME_VFS_TYPE_DRIVE))

`k` : |

### GNOME_VFS_TYPE_DRIVE

    #define GNOME_VFS_TYPE_DRIVE        (gnome_vfs_drive_get_type ())

### GNOME_VFS_DRIVE()

    #define GNOME_VFS_DRIVE(o)          (G_TYPE_CHECK_INSTANCE_CAST ((o), GNOME_VFS_TYPE_DRIVE, GnomeVFSDrive))

`o` : |

### GNOME_VFS_DRIVE_CLASS()

    #define GNOME_VFS_DRIVE_CLASS(k)    (G_TYPE_CHECK_CLASS_CAST((k), GNOME_VFS_TYPE_DRIVE, GnomeVFSDriveClass))

`k` : |

### gnome_vfs_drive_compare ()

    gint        gnome_vfs_drive_compare         (GnomeVFSDrive *a,
                                                 GnomeVFSDrive *b);

`a` : |
`b` : |
Returns : |

Since 2.6

### gnome_vfs_drive_eject ()

    void        gnome_vfs_drive_eject           (GnomeVFSDrive *drive,
                                                 GnomeVFSVolumeOpCallback callback,
                                                 gpointer user_data);

`drive` : |
`callback` : |
`user_data` : |

Since 2.6

### gnome_vfs_drive_get_activation_uri ()

    char*       gnome_vfs_drive_get_activation_uri
                                                (GnomeVFSDrive *drive);

`drive` : |
Returns : | a newly allocated string

Since 2.6

### gnome_vfs_drive_get_device_path ()

    char*       gnome_vfs_drive_get_device_path (GnomeVFSDrive *drive);

`drive` : |
Returns : | a newly allocated string

Since 2.6

### gnome_vfs_drive_get_device_type ()

    GnomeVFSDeviceType gnome_vfs_drive_get_device_type
                                                (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_get_display_name ()

    char*       gnome_vfs_drive_get_display_name
                                                (GnomeVFSDrive *drive);

`drive` : |
Returns : | a newly allocated string

Since 2.6

### gnome_vfs_drive_get_hal_udi ()

    char*       gnome_vfs_drive_get_hal_udi     (GnomeVFSDrive *drive);

`drive` : |
Returns : | a newly allocated string

Since 2.6

### gnome_vfs_drive_get_icon ()

    char*       gnome_vfs_drive_get_icon        (GnomeVFSDrive *drive);

`drive` : |
Returns : | a newly allocated string

Since 2.6

### gnome_vfs_drive_get_id ()

    gulong      gnome_vfs_drive_get_id          (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_get_mounted_volume ()

    GnomeVFSVolume* gnome_vfs_drive_get_mounted_volume
                                                (GnomeVFSDrive *drive);

### Warning

`gnome_vfs_drive_get_mounted_volume` is deprecated and should not be used in newly-written code.

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_get_mounted_volumes ()

    GList*      gnome_vfs_drive_get_mounted_volumes
                                                (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_volume_list_free ()

    void        gnome_vfs_drive_volume_list_free
                                                (GList *volumes);

`volumes` : |

Since 2.6

### gnome_vfs_drive_get_type ()

    GType       gnome_vfs_drive_get_type        (void);

Returns : |

### gnome_vfs_drive_is_connected ()

    gboolean    gnome_vfs_drive_is_connected    (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_is_mounted ()

    gboolean    gnome_vfs_drive_is_mounted      (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_is_user_visible ()

    gboolean    gnome_vfs_drive_is_user_visible (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_mount ()

    void        gnome_vfs_drive_mount           (GnomeVFSDrive *drive,
                                                 GnomeVFSVolumeOpCallback callback,
                                                 gpointer user_data);

`drive` : |
`callback` : |
`user_data` : |

Since 2.6

### gnome_vfs_drive_ref ()

    GnomeVFSDrive* gnome_vfs_drive_ref          (GnomeVFSDrive *drive);

`drive` : |
Returns : |

Since 2.6

### gnome_vfs_drive_unmount ()

    void        gnome_vfs_drive_unmount         (GnomeVFSDrive *drive,
                                                 GnomeVFSVolumeOpCallback callback,
                                                 gpointer user_data);

`drive` : |
`callback` : |
`user_data` : |

Since 2.6

### gnome_vfs_drive_unref ()

    void        gnome_vfs_drive_unref           (GnomeVFSDrive *drive);

`drive` : |

Since 2.6

## Signals

### The "volume-mounted" signal

    void        user_function                  (GnomeVFSDrive *vfsdrive,
                                                GnomeVFSVolume *arg1,
                                                gpointer user_data);

`vfsdrive` : | the object which received the signal.
`arg1` : |
`user_data` : | user data set when the signal handler was connected.

### The "volume-pre-unmount" signal

    void        user_function                  (GnomeVFSDrive *vfsdrive,
                                                GnomeVFSVolume *arg1,
                                                gpointer user_data);

`vfsdrive` : | the object which received the signal.
`arg1` : |
`user_data` : | user data set when the signal handler was connected.

### The "volume-unmounted" signal

    void        user_function                  (GnomeVFSDrive *vfsdrive,
                                                GnomeVFSVolume *arg1,
                                                gpointer user_data);

`vfsdrive` : | the object which received the signal.
`arg1` : |
`user_data` : | user data set when the signal handler was connected.