1
0
mirror of https://gitlab.com/libvirt/libvirt-python.git synced 2025-12-03 16:23:46 +03:00
Files
libvirt-python/libvirt-override-virDomainCheckpoint.py
Philipp Hahn ee5c856af7 Remove legacy libvirtError arguments
The fields have been deprecated in C with
git:f60dc0bc09f09c6817d6706a9edb1579a3e2b2b8

They are only passed to the libvirtError constructor, but not stored for
later or used anywhere else.

sed -ri '/raise libvirtError/s/, \w+=self(\._dom)?//' *.py

Signed-off-by: Philipp Hahn <hahn@univention.de>
2020-08-06 08:50:37 +02:00

20 lines
716 B
Python

def getConnect(self):
"""Get the connection that owns the domain that a checkpoint was created for"""
return self.connect()
def getDomain(self):
"""Get the domain that a checkpoint was created for"""
return self.domain()
def listAllChildren(self, flags=0):
"""List all child checkpoints and returns a list of checkpoint objects"""
ret = libvirtmod.virDomainCheckpointListAllChildren(self._o, flags)
if ret is None:
raise libvirtError("virDomainCheckpointListAllChildren() failed")
retlist = list()
for chkptr in ret:
retlist.append(virDomainCheckpoint(self.domain(), _obj=chkptr))
return retlist