Class Libvirt::StorageVol
In: ext/libvirt/_libvirt.c
Parent: Object

Methods

delete   download   free   info   key   name   path   pool   upload   wipe   xml_desc  

Constants

FILE = INT2NUM(VIR_STORAGE_VOL_FILE)   virStorageVolType
BLOCK = INT2NUM(VIR_STORAGE_VOL_BLOCK)
DELETE_NORMAL = INT2NUM(VIR_STORAGE_VOL_DELETE_NORMAL)   virStoragePoolDeleteFlags
DELETE_ZEROED = INT2NUM(VIR_STORAGE_VOL_DELETE_ZEROED)

Public Instance methods

Call virStorageVolDelete to delete this volume. This is a destructive operation.

[Source]

/*
 * call-seq:
 *   vol.delete(flags=0) -> nil
 *
 * Call +virStorageVolDelete+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolDelete]
 * to delete this volume.  This is a destructive operation.
 */
static VALUE libvirt_vol_delete(int argc, VALUE *argv, VALUE v) {

Call virStorageVolDownload to download the content of a volume as a stream.

[Source]

/*
 * call-seq:
 *   vol.download(stream, offset, length, flags=0) -> nil
 *
 * Call +virStorageVolDownload+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolDownload]
 * to download the content of a volume as a stream.
 */
static VALUE libvirt_vol_download(int argc, VALUE *argv, VALUE v) {

Call virStorageVolFree to free the storage volume object. After this call the storage volume object is no longer valid.

[Source]

/*
 * call-seq:
 *   vol.free -> nil
 *
 * Call +virStorageVolFree+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolFree]
 * to free the storage volume object.  After this call the storage volume object
 * is no longer valid.
 */
static VALUE libvirt_vol_free(VALUE s) {

Call virStorageVolGetInfo to retrieve information about this storage volume.

[Source]

/*
 * call-seq:
 *   vol.info -> Libvirt::StorageVolInfo
 *
 * Call +virStorageVolGetInfo+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetInfo]
 * to retrieve information about this storage volume.
 */
static VALUE libvirt_vol_info(VALUE v) {

Call virStorageVolGetKey to retrieve the key for this storage volume.

[Source]

/*
 * call-seq:
 *   vol.key -> string
 *
 * Call +virStorageVolGetKey+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetKey]
 * to retrieve the key for this storage volume.
 */
static VALUE libvirt_vol_key(VALUE v) {

Call virStorageVolGetName to retrieve the name of this storage volume.

[Source]

/*
 * call-seq:
 *   vol.name -> string
 *
 * Call +virStorageVolGetName+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetName]
 * to retrieve the name of this storage volume.
 */
static VALUE libvirt_vol_name(VALUE v) {

Call virStorageVolGetPath to retrieve the path for this storage volume.

[Source]

/*
 * call-seq:
 *   vol.path -> string
 *
 * Call +virStorageVolGetPath+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetPath]
 * to retrieve the path for this storage volume.
 */
static VALUE libvirt_vol_path(VALUE v) {

Call virStoragePoolLookupByVolume to retrieve the storage pool for this volume.

[Source]

/*
 * call-seq:
 *   vol.pool -> Libvirt::StoragePool
 *
 * Call +virStoragePoolLookupByVolume+[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolLookupByVolume]
 * to retrieve the storage pool for this volume.
 */
static VALUE libvirt_vol_get_pool(VALUE v) {

Call virStorageVolUpload to upload new content to a volume from a stream.

[Source]

/*
 * call-seq:
 *   vol.upload(stream, offset, length, flags=0) -> nil
 *
 * Call +virStorageVolUpload+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolUpload]
 * to upload new content to a volume from a stream.
 */
static VALUE libvirt_vol_upload(int argc, VALUE *argv, VALUE v) {

Call virStorageVolWipe to wipe the data from this storage volume. This is a destructive operation.

[Source]

/*
 * call-seq:
 *   vol.wipe(flags=0) -> nil
 *
 * Call +virStorageVolWipe+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolWipe]
 * to wipe the data from this storage volume.  This is a destructive operation.
 */
static VALUE libvirt_vol_wipe(int argc, VALUE *argv, VALUE v) {

Call virStorageVolGetXMLDesc to retrieve the xml for this storage volume.

[Source]

/*
 * call-seq:
 *   vol.xml_desc(flags=0) -> string
 *
 * Call +virStorageVolGetXMLDesc+[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetXMLDesc]
 * to retrieve the xml for this storage volume.
 */
static VALUE libvirt_vol_xml_desc(int argc, VALUE *argv, VALUE v) {

[Validate]