python: Add python bindings for virDomainMemoryStats

Enable virDomainMemoryStats in the python API.  dom.memoryStats() will return a
dictionary containing the supported statistics.  A dictionary is required
because the meaining of each quantity cannot be inferred from its index in a
list.

* python/generator.py: reenable bindings for this entry point
* python/libvirt-override-api.xml python/libvirt-override.c: the
  generator can't handle this new function, add the new binding,
  and the XML description
This commit is contained in:
Adam Litke
2009-12-20 13:48:37 +01:00
committed by Daniel Veillard
parent b6798b68cb
commit 2c345831a3
3 changed files with 50 additions and 2 deletions

View File

@@ -105,6 +105,11 @@
<arg name='domain' type='virDomainPtr' info='a domain object'/>
<arg name='path' type='char *' info='the path for the interface device'/>
</function>
<function name='virDomainMemoryStats' file='python'>
<info>Extracts memory statistics for a domain</info>
<return type='virDomainMemoryStats' info='a dictionary of statistics'/>
<arg name='domain' type='virDomainPtr' info='a domain object'/>
</function>
<function name="virNodeGetCellsFreeMemory" file='python'>
<info>Returns the available memory for a list of cells</info>
<arg name='conn' type='virConnectPtr' info='pointer to the hypervisor connection'/>