LibvirtGObject.StorageVol

g GObject.Object GObject.Object LibvirtGObject.StorageVol LibvirtGObject.StorageVol GObject.Object->LibvirtGObject.StorageVol

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

delete (flags)

download (stream, offset, length, flags)

get_config (flags)

get_info ()

get_name ()

get_path ()

resize (capacity, flags)

upload (stream, offset, length, flags)

Virtual Methods

Inherited:

GObject.Object (7)

Properties

Name

Type

Flags

Short Description

handle

r/w/co

The storage_vol handle

pool

LibvirtGObject.StoragePool

r/w/co

The containing storage pool

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent

GObject.Object

r

Class Details

class LibvirtGObject.StorageVol(**kwargs)
Bases:

GObject.Object

Abstract:

No

Structure:

LibvirtGObject.StorageVolClass

delete(flags)
Parameters:

flags (int) – the flags

Raises:

GLib.Error

Returns:

True on success, False otherwise

Return type:

bool

Deletes the storage volume self.

download(stream, offset, length, flags)
Parameters:
  • stream (LibvirtGObject.Stream) – stream to use as output

  • offset (int) – position in self to start reading from

  • length (int) – limit on amount of data to download, or 0 for downloading all data

  • flags (int) – extra flags, not used yet, pass 0

Raises:

GLib.Error

Returns:

True of success, False otherwise

Return type:

bool

get_config(flags)
Parameters:

flags (int) – the flags

Raises:

GLib.Error

Returns:

the config. The returned object should be unreffed with GObject.Object.unref() when no longer needed.

Return type:

LibvirtGConfig.StorageVol

get_info()
Raises:

GLib.Error

Returns:

the info. The returned object should be unreffed with GObject.Object.unref() when no longer needed.

Return type:

LibvirtGObject.StorageVolInfo

get_name()
Return type:

str

get_path()
Raises:

GLib.Error

Return type:

str

resize(capacity, flags)
Parameters:
Raises:

GLib.Error

Returns:

True success, False otherwise

Return type:

bool

Changes the capacity of the storage volume self to capacity.

upload(stream, offset, length, flags)
Parameters:
  • stream (LibvirtGObject.Stream) – stream to use as input

  • offset (int) – position in self to start to write to

  • length (int) – limit on amount of data to upload, or 0 for uploading all data

  • flags (int) – the flags, not set yet, pass 0

Raises:

GLib.Error

Returns:

True of success, False otherwise

Return type:

bool

Property Details

LibvirtGObject.StorageVol.props.handle
Name:

handle

Type:

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The storage_vol handle

LibvirtGObject.StorageVol.props.pool
Name:

pool

Type:

LibvirtGObject.StoragePool

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The containing storage pool