diff options
author | Peter Krempa <pkrempa@redhat.com> | 2017-03-29 16:59:39 +0200 |
---|---|---|
committer | Peter Krempa <pkrempa@redhat.com> | 2017-03-29 16:59:39 +0200 |
commit | a927799334a59b04c82dc21983fbb885fd7820d1 (patch) | |
tree | 5af546a7862ddfe6e78f6abf8bf636e01342181c /libvirt-override-virConnect.py | |
parent | f261fd3e3c85d7b21df8e3d63909d6c1f63cf6d0 (diff) | |
download | libvirt-python-a927799334a59b04c82dc21983fbb885fd7820d1.tar.gz |
event: Add handler for block threshold event
Unfortunately python doesn't generate those.
Diffstat (limited to 'libvirt-override-virConnect.py')
-rw-r--r-- | libvirt-override-virConnect.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/libvirt-override-virConnect.py b/libvirt-override-virConnect.py index 35009bb..f26e65a 100644 --- a/libvirt-override-virConnect.py +++ b/libvirt-override-virConnect.py @@ -252,6 +252,15 @@ cb(self, virDomain(self, _obj=dom), mtype, nsuri, opaque) return 0 + def _dispatchDomainEventBlockThresholdCallback(self, dom, dev, path, threshold, excess, cbData): + """Dispatches event to python user domain block device threshold event callbacks + """ + cb = cbData["cb"] + opaque = cbData["opaque"] + + cb(self, virDomain(self, _obj=dom), dev, path, threshold, excess, opaque) + return 0 + def domainEventDeregisterAny(self, callbackID): """Removes a Domain Event Callback. De-registering for a domain callback will disable delivery of this event type """ |