1
0
mirror of https://gitlab.com/libvirt/libvirt-python.git synced 2025-07-17 00:59:36 +03:00
Files
libvirt-python/libvirt-override-virNetwork.py
Daniel P. Berrangé 204d3c061b Add missing impl of virNetworkListAllPorts
This API needs manual impl as the generator cannot cope

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
2019-06-20 14:21:06 +01:00

12 lines
405 B
Python

def listAllPorts(self, flags=0):
"""List all domains and returns a list of domain objects"""
ret = libvirtmod.virNetworkListAllPorts(self._o, flags)
if ret is None:
raise libvirtError("virNetworkListAllPorts() failed", conn=self)
retlist = list()
for domptr in ret:
retlist.append(virNetwork(self, _obj=domptr))
return retlist