LibvirtGObject.Network

g GObject.Object GObject.Object LibvirtGObject.Network LibvirtGObject.Network GObject.Object->LibvirtGObject.Network

Subclasses:

None

Methods

Inherited:

GObject.Object (37)

Structs:

GObject.ObjectClass (5)

get_config (flags)

get_dhcp_leases (mac, flags)

get_name ()

get_uuid ()

Virtual Methods

Inherited:

GObject.Object (7)

do_started ()

do_stopped ()

Properties

Name

Type

Flags

Short Description

handle

r/w/co

The network handle

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Name

Type

Access

Description

parent

GObject.Object

r

Class Details

class LibvirtGObject.Network(**kwargs)
Bases:

GObject.Object

Abstract:

No

Structure:

LibvirtGObject.NetworkClass

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.Network

get_dhcp_leases(mac, flags)
Parameters:
  • mac (str or None) – The optional ASCII formatted MAC address of an interface

  • flags (int) – placeholder for flags, must be 0

Raises:

GLib.Error

Returns:

the list of network leases. Each object in the returned list should be unreffed with GObject.Object.unref() and the list itself using g_list_free, when no longer needed.

Return type:

[LibvirtGObject.NetworkDHCPLease]

This function fetches leases info of guests in the specified network. If the optional parameter mac is specified, the returned list will contain only lease info about a specific guest interface with mac. There can be multiple leases for a single mac because this API supports DHCPv6 too.

get_name()
Return type:

str

get_uuid()
Return type:

str

do_started() virtual
do_stopped() virtual

Property Details

LibvirtGObject.Network.props.handle
Name:

handle

Type:

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The network handle