Commit Graph

18 Commits

Author SHA1 Message Date
Miloslav Trmač
9dc3b99345 Secret manipulation API docs refresh & wire up python generator
Sample session:

>>> import libvirt
>>> c = libvirt.open('qemu:///session')

>>> c.listSecrets()
['12247729-47d2-a783-88ce-b329d4781cd3', 'reee', 'abc']

>>> s = c.secretDefineXML("<secret ephemeral='no' private='no'>\n<description>Something for use</description>\n<volume>/foo/bar</volume>\n</secret>\n")

>>> s.UUIDString()
'340c2dfb-811b-eda8-da9e-25ccd7bfd650'

>>> s.XMLDesc()
"<secret ephemeral='no' private='no'>\n  <uuid>340c2dfb-811b-eda8-da9e-25ccd7bfd650</uuid>\n  <description>Something for use</description>\n  <volume>/foo/bar</volume>\n</secret>\n"

>>> s.setValue('abc\0xx\xffx')
0

>>> s.value()
'abc\x00xx\xffx'

>>> s.undefine()
0

* python/generator.py: Add rules for virSecret APIs
* python/libvir.c, python/libvirt-python-api.xml: Manual impl of
  virSecretSetValue, virSecretGetValue$ and virConnectListSecrets APIs
* python/libvirt_wrap.h, python/types.c: Wrapper for virSecret objects
* docs/libvirt-api.xml, docs/libvirt-refs.xml,
  docs/html/libvirt-virterror.html, docs/html/libvirt-libvirt.html,
  docs/devhelp/libvirt-virterror.html, docs/devhelp/libvirt-libvirt.html:
  Re-generate with 'make api'
2009-09-01 18:27:06 +01:00
Jim Meyering
07613d2020 remove all trailing blank lines
by running this command:
git ls-files -z | xargs -0 perl -pi -0777 -e 's/\n\n+$/\n/'
This is in preparation for a more strict make syntax-check
rule that will detect trailing blank lines.
2009-07-16 15:06:42 +02:00
Daniel P. Berrange
c9e6c8c02f Add virInterface APIs to python code generator 2009-05-21 10:57:05 +00:00
Daniel P. Berrange
c673689430 Fix python bindings events code (David Lively) 2008-11-24 19:28:12 +00:00
Daniel P. Berrange
83928c2074 Python binding for node device APIs (David Lively) 2008-11-21 12:41:15 +00:00
Daniel P. Berrange
6d04effac7 Add a virFreeCallback to event loop APIs 2008-11-19 16:24:01 +00:00
Daniel Veillard
7b716fce8e * python/Makefile.am python/generator.py python/libvir.c
python/libvir.py python/libvirt_wrap.h python/types.c:
  adds support for events from the python bindings, also
  improves the generator allowing to embbed per function
  definition files, patch by Ben Guthro
* examples/domain-events/events-python/event-test.py: also
  adds a programming example
Daniel
2008-10-31 10:13:45 +00:00
Jim Meyering
5bf824ea10 convert TAB-based indentation in C sources to use only spaces
Done using this command (also includes .c.in and .h.in files):
for i in $(g ls-files|grep -E '\.[ch](\.in)?$'|grep -v gnulib); do
  expand -i $i > j && mv j $i;done
2008-04-10 16:54:54 +00:00
Richard W.M. Jones
bb8340c18d Many typos fixed (Atsushi SAKAI). 2008-02-29 12:53:10 +00:00
Daniel P. Berrange
859679f72a Added python binding for storage APIs 2008-02-20 15:26:22 +00:00
Richard W.M. Jones
4bfdb77aae Wed Dec 5 13:48:00 UTC 2007 Richard W.M. Jones <rjones@redhat.com>
* python/libvir.c, python/libvirt_wrap.h, qemud/qemud.c,
        qemud/remote.c, src/internal.h, src/openvz_conf.c,
        src/openvz_driver.c, src/proxy_internal.h, src/qemu_conf.c,
        src/qemu_driver.c, src/remote_internal.h, src/test.h, src/util.c,
        src/xen_unified.c, src/xen_unified.h, tests/nodeinfotest.c,
        tests/qemuxml2argvtest.c, tests/qemuxml2xmltest.c, tests/reconnect.c,
        tests/sexpr2xmltest.c, tests/virshtest.c, tests/xencapstest.c,
        tests/xmconfigtest.c, tests/xml2sexprtest.c:
        Change #include <> to #include "" for local includes.
        Removed many includes from src/internal.h and put them in
        the C files which actually use them.
        Removed <ansidecl.h> - unused.
        Added a comment around __func__.
        Removed a clashing redefinition of VERSION symbol.
        All limits (PATH_MAX etc) now done in src/internal.h, so we
        don't need to include those headers in other files.
2007-12-05 13:56:22 +00:00
Daniel P. Berrange
6a66941843 Added python bindings for networking APIs 2007-03-09 15:42:50 +00:00
Daniel P. Berrange
d6db609d74 Fixed up numerous compiler warnings 2007-03-06 21:55:44 +00:00
Daniel P. Berrange
a3cf19e62a Fix unsigned long wraparound in python binding 2006-11-15 19:40:00 +00:00
Daniel P. Berrange
9e5645393e Make python bindings threaded, by dropping/acquiring Python GIL where needed 2006-10-24 20:28:16 +00:00
Daniel Veillard
b62cdc1405 * configure.in libvirt.spec.in docs/examples/* include/Makefile.am
include/libvirt/virterror.h python/generator.py python/libvir.c
  python/libvirt_wrap.h src/driver.h src/internal.h src/test.h
  src/virsh.c src/virterror.c src/xend_internal.c src/xend_internal.h
  src/xml.c src/xml.h: moved the includes from include/ to
  include/libvirt to reflect the installed include tree. This
  avoid using "" in the includes themselves.
Daniel
2006-06-26 15:02:18 +00:00
Daniel Veillard
7743c7a7b1 * doc/site.xsl doc/libvir.html doc/*: added informations about
the Perl bindings, regenerated
* python/libvirt_wrap.h: added a missing include.
Daniel
2006-03-28 09:50:17 +00:00
Daniel Veillard
8c423e6c83 * //* : renamed the project libvirt , this affects all makefiles,
the specs, the icons, the docs, etc ...
* configure.in: prepare for 0.0.3
Daniel
2006-02-09 17:45:11 +00:00