1
0
mirror of https://gitlab.com/libvirt/libvirt-python.git synced 2025-07-15 20:59:34 +03:00
Files
libvirt-python/libvirt-override-virDomainCheckpoint.py
Eric Blake 358a8640fa Add virDomainCheckpoint APIs
Copies heavily from existing virDomainSnapshot handling, regarding
what special cases the generator has to be taught and what overrides
need to be written.

Signed-off-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
2019-07-29 13:39:39 -05:00

20 lines
718 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", conn=self)
retlist = list()
for chkptr in ret:
retlist.append(virDomainCheckpoint(self, _obj=chkptr))
return retlist