mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
* python/libvir.py python/libvirt-python-api.xml: more python
cleanups by Cole Robinson Daniel
This commit is contained in:
parent
b0a3d6809a
commit
c0626a02a9
@ -1,3 +1,8 @@
|
|||||||
|
Wed Jun 11 09:42:57 CEST 2008 Daniel Veillard <veillard@redhat.com>
|
||||||
|
|
||||||
|
* python/libvir.py python/libvirt-python-api.xml: more python
|
||||||
|
cleanups by Cole Robinson
|
||||||
|
|
||||||
Tue Jun 10 17:34:12 CEST 2008 Daniel Veillard <veillard@redhat.com>
|
Tue Jun 10 17:34:12 CEST 2008 Daniel Veillard <veillard@redhat.com>
|
||||||
|
|
||||||
* configure.in: patch from Cole Robinson to reactivate storage
|
* configure.in: patch from Cole Robinson to reactivate storage
|
||||||
|
@ -15,13 +15,17 @@ import types
|
|||||||
|
|
||||||
# The root of all libvirt errors.
|
# The root of all libvirt errors.
|
||||||
class libvirtError(Exception):
|
class libvirtError(Exception):
|
||||||
def __init__(self, msg, conn=None, dom=None, net=None):
|
def __init__(self, msg, conn=None, dom=None, net=None, pool=None, vol=None):
|
||||||
Exception.__init__(self, msg)
|
Exception.__init__(self, msg)
|
||||||
|
|
||||||
if dom is not None:
|
if dom is not None:
|
||||||
conn = dom._conn
|
conn = dom._conn
|
||||||
elif net is not None:
|
elif net is not None:
|
||||||
conn = net._conn
|
conn = net._conn
|
||||||
|
elif pool is not None:
|
||||||
|
conn = pool._conn
|
||||||
|
elif vol is not None:
|
||||||
|
conn = vol._conn
|
||||||
|
|
||||||
if conn is None:
|
if conn is None:
|
||||||
self.err = virGetLastError()
|
self.err = virGetLastError()
|
||||||
|
@ -83,6 +83,11 @@
|
|||||||
<return type='int' info='the autostart flag, or None in case of error'/>
|
<return type='int' info='the autostart flag, or None in case of error'/>
|
||||||
<arg name='domain' type='virDomainPtr' info='a network object'/>
|
<arg name='domain' type='virDomainPtr' info='a network object'/>
|
||||||
</function>
|
</function>
|
||||||
|
<function name='virStoragePoolGetAutostart' file='python'>
|
||||||
|
<info>Extract the autostart flag for a storage pool</info>
|
||||||
|
<return type='int' info='the autostart flag, or None in case of error'/>
|
||||||
|
<arg name='pool' type='virStoragePoolPtr' info='a storage pool object'/>
|
||||||
|
</function>
|
||||||
<function name='virDomainBlockStats' file='python'>
|
<function name='virDomainBlockStats' file='python'>
|
||||||
<info>Extracts block device statistics for a domain</info>
|
<info>Extracts block device statistics for a domain</info>
|
||||||
<return type='virDomainBlockStats' info='a tuple of statistics'/>
|
<return type='virDomainBlockStats' info='a tuple of statistics'/>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user