[Pkg-libvirt-commits] [ruby-libvirt] 01/05: New upstream version 0.7.0
Guido Guenther
agx at moszumanska.debian.org
Mon Oct 10 19:41:17 UTC 2016
This is an automated email from the git hooks/post-receive script.
agx pushed a commit to annotated tag debian/0.7.0-1
in repository ruby-libvirt.
commit b96e308a215bd9836005f520fb215fe121e30510
Author: Guido Günther <agx at sigxcpu.org>
Date: Mon Oct 10 21:23:36 2016 +0200
New upstream version 0.7.0
---
COPYING | 2 +-
NEWS | 11 ++
Rakefile | 2 +-
ext/libvirt/_libvirt.c | 14 +-
ext/libvirt/common.c | 2 +-
ext/libvirt/connect.c | 224 ++++++++++++++++--------------
ext/libvirt/domain.c | 347 +++++++++++++++++++++++++++++------------------
ext/libvirt/extconf.h | 12 ++
ext/libvirt/extconf.rb | 13 ++
ext/libvirt/interface.c | 18 +--
ext/libvirt/network.c | 50 ++++---
ext/libvirt/nodedevice.c | 24 ++--
ext/libvirt/nwfilter.c | 12 +-
ext/libvirt/secret.c | 20 +--
ext/libvirt/storage.c | 99 +++++++++-----
ext/libvirt/stream.c | 24 ++--
16 files changed, 521 insertions(+), 353 deletions(-)
diff --git a/COPYING b/COPYING
index cf9b6b9..0908c16 100644
--- a/COPYING
+++ b/COPYING
@@ -3,7 +3,7 @@
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
diff --git a/NEWS b/NEWS
index 8af4530..3378ffe 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,14 @@
+2016-09-22 0.7.0
+ * Fix network lease API to allow arguments that libvirt allows
+ * Implement VIRT_STORAGE_POOL_CREATE flags
+ * Implement more VIR_STORAGE_VOL flags
+ * Implement VIR_DOMAIN_QEMU_AGENT_COMMAND_SHUTDOWN
+ * Implement virDomainDefineXMLFlags
+ * Implement virDomainRename
+ * Implement virDomainSetUserPassword
+ * Implement VIR_DOMAIN_TIME_SYNC
+ * Fix the return value from virStreamSourceFunc so volume upload works
+
2015-11-20 0.6.0
* Fix possible buffer overflow
* Fix storage volume creation error messages
diff --git a/Rakefile b/Rakefile
index 331cd30..a29182c 100644
--- a/Rakefile
+++ b/Rakefile
@@ -21,7 +21,7 @@ require 'rubygems/package_task'
require 'rbconfig'
PKG_NAME='ruby-libvirt'
-PKG_VERSION='0.6.0'
+PKG_VERSION='0.7.0'
EXT_CONF='ext/libvirt/extconf.rb'
MAKEFILE="ext/libvirt/Makefile"
diff --git a/ext/libvirt/_libvirt.c b/ext/libvirt/_libvirt.c
index 9641b1e..e0a3671 100644
--- a/ext/libvirt/_libvirt.c
+++ b/ext/libvirt/_libvirt.c
@@ -2,7 +2,7 @@
* libvirt.c: Ruby bindings for libvirt
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -60,7 +60,7 @@ static void rubyLibvirtErrorFunc(void *RUBY_LIBVIRT_UNUSED(userdata),
* call-seq:
* Libvirt::version(type=nil) -> [ libvirt_version, type_version ]
*
- * Call virGetVersion[http://www.libvirt.org/html/libvirt-libvirt.html#virGetVersion]
+ * Call virGetVersion[http://www.libvirt.org/html/libvirt-libvirt-host.html#virGetVersion]
* to get the version of libvirt and of the hypervisor TYPE.
*/
static VALUE libvirt_version(int argc, VALUE *argv,
@@ -90,7 +90,7 @@ static VALUE libvirt_version(int argc, VALUE *argv,
* call-seq:
* Libvirt::open(uri=nil) -> Libvirt::Connect
*
- * Call virConnectOpen[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectOpen]
+ * Call virConnectOpen[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectOpen]
* to open a connection to a URL.
*/
static VALUE libvirt_open(int argc, VALUE *argv, VALUE RUBY_LIBVIRT_UNUSED(m))
@@ -111,7 +111,7 @@ static VALUE libvirt_open(int argc, VALUE *argv, VALUE RUBY_LIBVIRT_UNUSED(m))
* call-seq:
* Libvirt::open_read_only(uri=nil) -> Libvirt::Connect
*
- * Call virConnectOpenReadOnly[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectOpenReadOnly]
+ * Call virConnectOpenReadOnly[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectOpenReadOnly]
* to open a read-only connection to a URL.
*/
static VALUE libvirt_open_read_only(int argc, VALUE *argv,
@@ -184,7 +184,7 @@ static int libvirt_auth_callback_wrapper(virConnectCredentialPtr cred,
* call-seq:
* Libvirt::open_auth(uri=nil, credlist=nil, userdata=nil, flags=0) {|...| authentication block} -> Libvirt::Connect
*
- * Call virConnectOpenAuth[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectOpenAuth]
+ * Call virConnectOpenAuth[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectOpenAuth]
* to open a connection to a libvirt URI, with a possible authentication block.
* If an authentication block is desired, then credlist should be an array that
* specifies which credentials the authentication block is willing to support;
@@ -575,7 +575,7 @@ static int is_symbol_proc_or_nil(VALUE handle)
* call-seq:
* Libvirt::event_register_impl(add_handle=nil, update_handle=nil, remove_handle=nil, add_timeout=nil, update_timeout=nil, remove_timeout=nil) -> Qnil
*
- * Call virEventRegisterImpl[http://www.libvirt.org/html/libvirt-libvirt.html#virEventRegisterImpl]
+ * Call virEventRegisterImpl[http://www.libvirt.org/html/libvirt-libvirt-event.html#virEventRegisterImpl]
* to register callback handlers for handles and timeouts. These handles and
* timeouts are used as part of the libvirt infrastructure for generating
* domain events. Each callback must be a Symbol (that is the name of a
@@ -652,7 +652,7 @@ static VALUE libvirt_conn_event_register_impl(int argc, VALUE *argv,
* call-seq:
* Libvirt::lxc_enter_security_label(model, label, flags=0) -> Libvirt::Domain::SecurityLabel
*
- * Call virDomainLxcEnterSecurityLabel[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainLxcEnterSecurityLabel]
+ * Call virDomainLxcEnterSecurityLabel
* to attach to the security label specified by label in the security model
* specified by model. The return object is a Libvirt::Domain::SecurityLabel
* which may be able to be used to move back to the previous label.
diff --git a/ext/libvirt/common.c b/ext/libvirt/common.c
index be483fd..cf7dd93 100644
--- a/ext/libvirt/common.c
+++ b/ext/libvirt/common.c
@@ -2,7 +2,7 @@
* common.c: Common utilities for the ruby libvirt bindings
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013,2014 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
diff --git a/ext/libvirt/connect.c b/ext/libvirt/connect.c
index bbdbc94..54daa63 100644
--- a/ext/libvirt/connect.c
+++ b/ext/libvirt/connect.c
@@ -2,7 +2,7 @@
* connect.c: virConnect methods
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013,2014 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -112,7 +112,7 @@ virConnectPtr ruby_libvirt_connect_get(VALUE c)
* call-seq:
* conn.close -> nil
*
- * Call virConnectClose[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectClose]
+ * Call virConnectClose[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectClose]
* to close the connection.
*/
static VALUE libvirt_connect_close(VALUE c)
@@ -145,7 +145,7 @@ static VALUE libvirt_connect_closed_p(VALUE c)
* call-seq:
* conn.type -> String
*
- * Call virConnectGetType[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetType]
+ * Call virConnectGetType[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetType]
* to retrieve the type of hypervisor for this connection.
*/
static VALUE libvirt_connect_type(VALUE c)
@@ -159,7 +159,7 @@ static VALUE libvirt_connect_type(VALUE c)
* call-seq:
* conn.version -> Fixnum
*
- * Call virConnectGetVersion[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetVersion]
+ * Call virConnectGetVersion[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetVersion]
* to retrieve the version of the hypervisor for this connection.
*/
static VALUE libvirt_connect_version(VALUE c)
@@ -179,7 +179,7 @@ static VALUE libvirt_connect_version(VALUE c)
* call-seq:
* conn.libversion -> Fixnum
*
- * Call virConnectGetLibVersion[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetLibVersion]
+ * Call virConnectGetLibVersion[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetLibVersion]
* to retrieve the version of the libvirt library for this connection.
*/
static VALUE libvirt_connect_libversion(VALUE c)
@@ -200,7 +200,7 @@ static VALUE libvirt_connect_libversion(VALUE c)
* call-seq:
* conn.hostname -> String
*
- * Call virConnectGetHostname[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetHostname]
+ * Call virConnectGetHostname[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetHostname]
* to retrieve the hostname of the hypervisor for this connection.
*/
static VALUE libvirt_connect_hostname(VALUE c)
@@ -214,7 +214,7 @@ static VALUE libvirt_connect_hostname(VALUE c)
* call-seq:
* conn.uri -> String
*
- * Call virConnectGetURI[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetURI]
+ * Call virConnectGetURI[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetURI]
* to retrieve the canonical URI for this connection.
*/
static VALUE libvirt_connect_uri(VALUE c)
@@ -228,7 +228,7 @@ static VALUE libvirt_connect_uri(VALUE c)
* call-seq:
* conn.max_vcpus(type=nil) -> Fixnum
*
- * Call virConnectGetMaxVcpus[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetMaxVcpus]
+ * Call virConnectGetMaxVcpus[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetMaxVcpus]
* to retrieve the maximum number of virtual cpus supported by the hypervisor
* for this connection.
*/
@@ -248,7 +248,7 @@ static VALUE libvirt_connect_max_vcpus(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.node_info -> Libvirt::Connect::Nodeinfo
*
- * Call virNodeGetInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetInfo]
+ * Call virNodeGetInfo[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetInfo]
* to retrieve information about the node for this connection.
*/
static VALUE libvirt_connect_node_info(VALUE c)
@@ -278,7 +278,7 @@ static VALUE libvirt_connect_node_info(VALUE c)
* call-seq:
* conn.node_free_memory -> Fixnum
*
- * Call virNodeGetFreeMemory[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetFreeMemory]
+ * Call virNodeGetFreeMemory[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetFreeMemory]
* to retrieve the amount of free memory available on the host for this
* connection.
*/
@@ -299,7 +299,7 @@ static VALUE libvirt_connect_node_free_memory(VALUE c)
* call-seq:
* conn.node_cells_free_memory(startCell=0, maxCells=#nodeCells) -> list
*
- * Call virNodeGetCellsFreeMemory[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetCellsFreeMemory]
+ * Call virNodeGetCellsFreeMemory[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetCellsFreeMemory]
* to retrieve the amount of free memory in each NUMA cell on the host for
* this connection.
*/
@@ -352,7 +352,7 @@ static VALUE libvirt_connect_node_cells_free_memory(int argc, VALUE *argv,
* call-seq:
* conn.node_security_model -> Libvirt::Connect::NodeSecurityModel
*
- * Call virNodeGetSecurityModel[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetSecurityModel]
+ * Call virNodeGetSecurityModel[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetSecurityModel]
* to retrieve the security model in use on the host for this connection.
*/
static VALUE libvirt_connect_node_security_model(VALUE c)
@@ -379,7 +379,7 @@ static VALUE libvirt_connect_node_security_model(VALUE c)
* call-seq:
* conn.encrypted? -> [True|False]
*
- * Call virConnectIsEncrypted[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectIsEncrypted]
+ * Call virConnectIsEncrypted[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectIsEncrypted]
* to determine if the connection is encrypted.
*/
static VALUE libvirt_connect_encrypted_p(VALUE c)
@@ -395,7 +395,7 @@ static VALUE libvirt_connect_encrypted_p(VALUE c)
* call-seq:
* conn.secure? -> [True|False]
*
- * Call virConnectIsSecure[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectIsSecure]
+ * Call virConnectIsSecure[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectIsSecure]
* to determine if the connection is secure.
*/
static VALUE libvirt_connect_secure_p(VALUE c)
@@ -410,7 +410,7 @@ static VALUE libvirt_connect_secure_p(VALUE c)
* call-seq:
* conn.capabilities -> String
*
- * Call virConnectGetCapabilities[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetCapabilities]
+ * Call virConnectGetCapabilities[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetCapabilities]
* to retrieve the capabilities XML for this connection.
*/
static VALUE libvirt_connect_capabilities(VALUE c)
@@ -425,7 +425,7 @@ static VALUE libvirt_connect_capabilities(VALUE c)
* call-seq:
* conn.compare_cpu(xml, flags=0) -> compareflag
*
- * Call virConnectCompareCPU[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectCompareCPU]
+ * Call virConnectCompareCPU[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectCompareCPU]
* to compare the host CPU with the XML contained in xml. Returns one of
* Libvirt::CPU_COMPARE_ERROR, Libvirt::CPU_COMPARE_INCOMPATIBLE,
* Libvirt::CPU_COMPARE_IDENTICAL, or Libvirt::CPU_COMPARE_SUPERSET.
@@ -450,7 +450,7 @@ static VALUE libvirt_connect_compare_cpu(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.baseline_cpu([xml, xml2, ...], flags=0) -> XML
*
- * Call virConnectBaselineCPU[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectBaselineCPU]
+ * Call virConnectBaselineCPU[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectBaselineCPU]
* to compare the most feature-rich CPU which is compatible with all
* given host CPUs.
*/
@@ -788,7 +788,7 @@ static int domain_event_graphics_callback(virConnectPtr conn, virDomainPtr dom,
* call-seq:
* conn.domain_event_register_any(eventID, callback, dom=nil, opaque=nil) -> Fixnum
*
- * Call virConnectDomainEventRegisterAny[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectDomainEventRegisterAny]
+ * Call virConnectDomainEventRegisterAny[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectDomainEventRegisterAny]
* to register callback for eventID with libvirt. The eventID must be one of
* the Libvirt::Connect::DOMAIN_EVENT_ID_* constants. The callback can either
* be a Symbol (that is the name of a method to callback) or a Proc. Note that
@@ -873,7 +873,7 @@ static VALUE libvirt_connect_domain_event_register_any(int argc, VALUE *argv,
* call-seq:
* conn.domain_event_deregister_any(callbackID) -> nil
*
- * Call virConnectDomainEventDeregisterAny[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectDomainEventDeregisterAny]
+ * Call virConnectDomainEventDeregisterAny[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectDomainEventDeregisterAny]
* to deregister a callback from libvirt. The callbackID must be a
* libvirt-specific handle returned by domain_event_register_any.
*/
@@ -905,7 +905,7 @@ static int domain_event_callback(virConnectPtr conn,
* call-seq:
* conn.domain_event_register(callback, opaque=nil) -> nil
*
- * Call virConnectDomainEventRegister[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectDomainEventRegister]
+ * Call virConnectDomainEventRegister[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectDomainEventRegister]
* to register callback for domain lifecycle events with libvirt. The
* callback can either be a Symbol (that is the name of a method to callback)
* or a Proc. The callback must accept 5 parameters: Libvirt::Connect,
@@ -941,7 +941,7 @@ static VALUE libvirt_connect_domain_event_register(int argc, VALUE *argv,
* call-seq:
* conn.domain_event_deregister(callback) -> nil
*
- * Call virConnectDomainEventDeregister[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectDomainEventDeregister]
+ * Call virConnectDomainEventDeregister[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectDomainEventDeregister]
* to deregister the event callback from libvirt. This method is deprecated
* in favor of domain_event_deregister_any (though they cannot be mixed; if
* the callback was registered with domain_event_register, it must be
@@ -960,7 +960,7 @@ static VALUE libvirt_connect_domain_event_deregister(VALUE c)
* call-seq:
* conn.num_of_domains -> Fixnum
*
- * Call virConnectNumOfDomains[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfDomains]
+ * Call virConnectNumOfDomains[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectNumOfDomains]
* to retrieve the number of active domains on this connection.
*/
static VALUE libvirt_connect_num_of_domains(VALUE c)
@@ -972,7 +972,7 @@ static VALUE libvirt_connect_num_of_domains(VALUE c)
* call-seq:
* conn.list_domains -> list
*
- * Call virConnectListDomains[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListDomains]
+ * Call virConnectListDomains[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectListDomains]
* to retrieve a list of active domain IDs on this connection.
*/
static VALUE libvirt_connect_list_domains(VALUE c)
@@ -1008,7 +1008,7 @@ static VALUE libvirt_connect_list_domains(VALUE c)
* call-seq:
* conn.num_of_defined_domains -> Fixnum
*
- * Call virConnectNumOfDefinedDomains[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfDefinedDomains]
+ * Call virConnectNumOfDefinedDomains[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectNumOfDefinedDomains]
* to retrieve the number of inactive domains on this connection.
*/
static VALUE libvirt_connect_num_of_defined_domains(VALUE c)
@@ -1020,7 +1020,7 @@ static VALUE libvirt_connect_num_of_defined_domains(VALUE c)
* call-seq:
* conn.list_defined_domains -> list
*
- * Call virConnectListDefinedDomains[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListDefinedDomains]
+ * Call virConnectListDefinedDomains[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectListDefinedDomains]
* to retrieve a list of inactive domain names on this connection.
*/
static VALUE libvirt_connect_list_defined_domains(VALUE c)
@@ -1032,7 +1032,7 @@ static VALUE libvirt_connect_list_defined_domains(VALUE c)
* call-seq:
* conn.create_domain_linux(xml, flags=0) -> Libvirt::Domain
*
- * Call virDomainCreateLinux[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCreateLinux]
+ * Call virDomainCreateLinux[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCreateLinux]
* to start a transient domain from the given XML. Deprecated; use
* conn.create_domain_xml instead.
*/
@@ -1057,7 +1057,7 @@ static VALUE libvirt_connect_create_linux(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.create_domain_xml(xml, flags=0) -> Libvirt::Domain
*
- * Call virDomainCreateXML[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCreateXML]
+ * Call virDomainCreateXML[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCreateXML]
* to start a transient domain from the given XML.
*/
static VALUE libvirt_connect_create_domain_xml(int argc, VALUE *argv, VALUE c)
@@ -1080,7 +1080,7 @@ static VALUE libvirt_connect_create_domain_xml(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.lookup_domain_by_name(name) -> Libvirt::Domain
*
- * Call virDomainLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainLookupByName]
+ * Call virDomainLookupByName[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainLookupByName]
* to retrieve a domain object for name.
*/
static VALUE libvirt_connect_lookup_domain_by_name(VALUE c, VALUE name)
@@ -1100,7 +1100,7 @@ static VALUE libvirt_connect_lookup_domain_by_name(VALUE c, VALUE name)
* call-seq:
* conn.lookup_domain_by_id(id) -> Libvirt::Domain
*
- * Call virDomainLookupByID[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainLookupByID]
+ * Call virDomainLookupByID[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainLookupByID]
* to retrieve a domain object for id.
*/
static VALUE libvirt_connect_lookup_domain_by_id(VALUE c, VALUE id)
@@ -1119,7 +1119,7 @@ static VALUE libvirt_connect_lookup_domain_by_id(VALUE c, VALUE id)
* call-seq:
* conn.lookup_domain_by_uuid(uuid) -> Libvirt::Domain
*
- * Call virDomainLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainLookupByUUIDString]
+ * Call virDomainLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainLookupByUUIDString]
* to retrieve a domain object for uuid.
*/
static VALUE libvirt_connect_lookup_domain_by_uuid(VALUE c, VALUE uuid)
@@ -1137,16 +1137,30 @@ static VALUE libvirt_connect_lookup_domain_by_uuid(VALUE c, VALUE uuid)
/*
* call-seq:
- * conn.define_domain_xml(xml) -> Libvirt::Domain
+ * conn.define_domain_xml(xml, flags=0) -> Libvirt::Domain
*
- * Call virDomainDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainDefineXML]
+ * Call virDomainDefineXML[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainDefineXML]
* to define a permanent domain on this connection.
*/
-static VALUE libvirt_connect_define_domain_xml(VALUE c, VALUE xml)
+static VALUE libvirt_connect_define_domain_xml(int argc, VALUE *argv, VALUE c)
{
virDomainPtr dom;
+ VALUE xml;
+ VALUE flags;
+
+ rb_scan_args(argc, argv, "11", &xml, &flags);
+#if HAVE_VIRDOMAINDEFINEXMLFLAGS
+ dom = virDomainDefineXMLFlags(ruby_libvirt_connect_get(c),
+ StringValueCStr(xml),
+ ruby_libvirt_value_to_uint(flags));
+#else
+ if (ruby_libvirt_value_to_uint(flags) != 0) {
+ rb_raise(e_NoSupportError, "Non-zero flags not supported");
+ }
dom = virDomainDefineXML(ruby_libvirt_connect_get(c), StringValueCStr(xml));
+#endif
+
ruby_libvirt_raise_error_if(dom == NULL, e_DefinitionError,
"virDomainDefineXML",
ruby_libvirt_connect_get(c));
@@ -1159,7 +1173,7 @@ static VALUE libvirt_connect_define_domain_xml(VALUE c, VALUE xml)
* call-seq:
* conn.domain_xml_from_native(nativeFormat, xml, flags=0) -> String
*
- * Call virConnectDomainXMLFromNative[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectDomainXMLFromNative]
+ * Call virConnectDomainXMLFromNative[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectDomainXMLFromNative]
* to convert a native hypervisor domain representation to libvirt XML.
*/
static VALUE libvirt_connect_domain_xml_from_native(int argc, VALUE *argv,
@@ -1183,7 +1197,7 @@ static VALUE libvirt_connect_domain_xml_from_native(int argc, VALUE *argv,
* call-seq:
* conn.domain_xml_to_native(nativeFormat, xml, flags=0) -> String
*
- * Call virConnectDomainXMLToNative[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectDomainXMLToNative]
+ * Call virConnectDomainXMLToNative[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectDomainXMLToNative]
* to convert libvirt XML to a native domain hypervisor representation.
*/
static VALUE libvirt_connect_domain_xml_to_native(int argc, VALUE *argv,
@@ -1207,7 +1221,7 @@ static VALUE libvirt_connect_domain_xml_to_native(int argc, VALUE *argv,
* call-seq:
* conn.num_of_interfaces -> Fixnum
*
- * Call virConnectNumOfInterfaces[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfInterfaces]
+ * Call virConnectNumOfInterfaces[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virConnectNumOfInterfaces]
* to retrieve the number of active interfaces on this connection.
*/
static VALUE libvirt_connect_num_of_interfaces(VALUE c)
@@ -1219,7 +1233,7 @@ static VALUE libvirt_connect_num_of_interfaces(VALUE c)
* call-seq:
* conn.list_interfaces -> list
*
- * Call virConnectListInterfaces[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListInterfaces]
+ * Call virConnectListInterfaces[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virConnectListInterfaces]
* to retrieve a list of active interface names on this connection.
*/
static VALUE libvirt_connect_list_interfaces(VALUE c)
@@ -1231,7 +1245,7 @@ static VALUE libvirt_connect_list_interfaces(VALUE c)
* call-seq:
* conn.num_of_defined_interfaces -> Fixnum
*
- * Call virConnectNumOfDefinedInterfaces[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfDefinedInterfaces]
+ * Call virConnectNumOfDefinedInterfaces[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virConnectNumOfDefinedInterfaces]
* to retrieve the number of inactive interfaces on this connection.
*/
static VALUE libvirt_connect_num_of_defined_interfaces(VALUE c)
@@ -1243,7 +1257,7 @@ static VALUE libvirt_connect_num_of_defined_interfaces(VALUE c)
* call-seq:
* conn.list_defined_interfaces -> list
*
- * Call virConnectListDefinedInterfaces[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListDefinedInterfaces]
+ * Call virConnectListDefinedInterfaces[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virConnectListDefinedInterfaces]
* to retrieve a list of inactive interface names on this connection.
*/
static VALUE libvirt_connect_list_defined_interfaces(VALUE c)
@@ -1255,7 +1269,7 @@ static VALUE libvirt_connect_list_defined_interfaces(VALUE c)
* call-seq:
* conn.lookup_interface_by_name(name) -> Libvirt::Interface
*
- * Call virInterfaceLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceLookupByName]
+ * Call virInterfaceLookupByName[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceLookupByName]
* to retrieve an interface object by name.
*/
static VALUE libvirt_connect_lookup_interface_by_name(VALUE c, VALUE name)
@@ -1275,7 +1289,7 @@ static VALUE libvirt_connect_lookup_interface_by_name(VALUE c, VALUE name)
* call-seq:
* conn.lookup_interface_by_mac(mac) -> Libvirt::Interface
*
- * Call virInterfaceLookupByMACString[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceLookupByMACString]
+ * Call virInterfaceLookupByMACString[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceLookupByMACString]
* to retrieve an interface object by MAC address.
*/
static VALUE libvirt_connect_lookup_interface_by_mac(VALUE c, VALUE mac)
@@ -1295,7 +1309,7 @@ static VALUE libvirt_connect_lookup_interface_by_mac(VALUE c, VALUE mac)
* call-seq:
* conn.define_interface_xml(xml, flags=0) -> Libvirt::Interface
*
- * Call virInterfaceDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceDefineXML]
+ * Call virInterfaceDefineXML[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceDefineXML]
* to define a new interface from xml.
*/
static VALUE libvirt_connect_define_interface_xml(int argc, VALUE *argv,
@@ -1321,7 +1335,7 @@ static VALUE libvirt_connect_define_interface_xml(int argc, VALUE *argv,
* call-seq:
* conn.num_of_networks -> Fixnum
*
- * Call virConnectNumOfNetworks[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfNetworks]
+ * Call virConnectNumOfNetworks[http://www.libvirt.org/html/libvirt-libvirt-network.html#virConnectNumOfNetworks]
* to retrieve the number of active networks on this connection.
*/
static VALUE libvirt_connect_num_of_networks(VALUE c)
@@ -1333,7 +1347,7 @@ static VALUE libvirt_connect_num_of_networks(VALUE c)
* call-seq:
* conn.list_networks -> list
*
- * Call virConnectListNetworks[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListNetworks]
+ * Call virConnectListNetworks[http://www.libvirt.org/html/libvirt-libvirt-network.html#virConnectListNetworks]
* to retrieve a list of active network names on this connection.
*/
static VALUE libvirt_connect_list_networks(VALUE c)
@@ -1345,7 +1359,7 @@ static VALUE libvirt_connect_list_networks(VALUE c)
* call-seq:
* conn.num_of_defined_networks -> Fixnum
*
- * Call virConnectNumOfDefinedNetworks[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfDefinedNetworks]
+ * Call virConnectNumOfDefinedNetworks[http://www.libvirt.org/html/libvirt-libvirt-network.html#virConnectNumOfDefinedNetworks]
* to retrieve the number of inactive networks on this connection.
*/
static VALUE libvirt_connect_num_of_defined_networks(VALUE c)
@@ -1357,7 +1371,7 @@ static VALUE libvirt_connect_num_of_defined_networks(VALUE c)
* call-seq:
* conn.list_of_defined_networks -> list
*
- * Call virConnectListDefinedNetworks[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListDefinedNetworks]
+ * Call virConnectListDefinedNetworks[http://www.libvirt.org/html/libvirt-libvirt-network.html#virConnectListDefinedNetworks]
* to retrieve a list of inactive network names on this connection.
*/
static VALUE libvirt_connect_list_defined_networks(VALUE c)
@@ -1369,7 +1383,7 @@ static VALUE libvirt_connect_list_defined_networks(VALUE c)
* call-seq:
* conn.lookup_network_by_name(name) -> Libvirt::Network
*
- * Call virNetworkLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkLookupByName]
+ * Call virNetworkLookupByName[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkLookupByName]
* to retrieve a network object by name.
*/
static VALUE libvirt_connect_lookup_network_by_name(VALUE c, VALUE name)
@@ -1389,7 +1403,7 @@ static VALUE libvirt_connect_lookup_network_by_name(VALUE c, VALUE name)
* call-seq:
* conn.lookup_network_by_uuid(uuid) -> Libvirt::Network
*
- * Call virNetworkLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkLookupByUUIDString]
+ * Call virNetworkLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkLookupByUUIDString]
* to retrieve a network object by UUID.
*/
static VALUE libvirt_connect_lookup_network_by_uuid(VALUE c, VALUE uuid)
@@ -1409,7 +1423,7 @@ static VALUE libvirt_connect_lookup_network_by_uuid(VALUE c, VALUE uuid)
* call-seq:
* conn.create_network_xml(xml) -> Libvirt::Network
*
- * Call virNetworkCreateXML[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkCreateXML]
+ * Call virNetworkCreateXML[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkCreateXML]
* to start a new transient network from xml.
*/
static VALUE libvirt_connect_create_network_xml(VALUE c, VALUE xml)
@@ -1428,7 +1442,7 @@ static VALUE libvirt_connect_create_network_xml(VALUE c, VALUE xml)
* call-seq:
* conn.define_network_xml(xml) -> Libvirt::Network
*
- * Call virNetworkDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkDefineXML]
+ * Call virNetworkDefineXML[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkDefineXML]
* to define a new permanent network from xml.
*/
static VALUE libvirt_connect_define_network_xml(VALUE c, VALUE xml)
@@ -1450,7 +1464,7 @@ static VALUE libvirt_connect_define_network_xml(VALUE c, VALUE xml)
* call-seq:
* conn.num_of_nodedevices(cap=nil, flags=0) -> Fixnum
*
- * Call virNodeNumOfDevices[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeNumOfDevices]
+ * Call virNodeNumOfDevices[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeNumOfDevices]
* to retrieve the number of node devices on this connection.
*/
static VALUE libvirt_connect_num_of_nodedevices(int argc, VALUE *argv, VALUE c)
@@ -1474,7 +1488,7 @@ static VALUE libvirt_connect_num_of_nodedevices(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.list_nodedevices(cap=nil, flags=0) -> list
*
- * Call virNodeListDevices[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeListDevices]
+ * Call virNodeListDevices[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeListDevices]
* to retrieve a list of node device names on this connection.
*/
static VALUE libvirt_connect_list_nodedevices(int argc, VALUE *argv, VALUE c)
@@ -1515,7 +1529,7 @@ static VALUE libvirt_connect_list_nodedevices(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.lookup_nodedevice_by_name(name) -> Libvirt::NodeDevice
*
- * Call virNodeDeviceLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceLookupByName]
+ * Call virNodeDeviceLookupByName[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceLookupByName]
* to retrieve a nodedevice object by name.
*/
static VALUE libvirt_connect_lookup_nodedevice_by_name(VALUE c, VALUE name)
@@ -1537,7 +1551,7 @@ static VALUE libvirt_connect_lookup_nodedevice_by_name(VALUE c, VALUE name)
* call-seq:
* conn.create_nodedevice_xml(xml, flags=0) -> Libvirt::NodeDevice
*
- * Call virNodeDeviceCreateXML[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceCreateXML]
+ * Call virNodeDeviceCreateXML[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceCreateXML]
* to create a new node device from xml.
*/
static VALUE libvirt_connect_create_nodedevice_xml(int argc, VALUE *argv,
@@ -1566,7 +1580,7 @@ static VALUE libvirt_connect_create_nodedevice_xml(int argc, VALUE *argv,
* call-seq:
* conn.num_of_nwfilters -> Fixnum
*
- * Call virConnectNumOfNWFilters[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfNWFilters]
+ * Call virConnectNumOfNWFilters[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virConnectNumOfNWFilters]
* to retrieve the number of network filters on this connection.
*/
static VALUE libvirt_connect_num_of_nwfilters(VALUE c)
@@ -1578,7 +1592,7 @@ static VALUE libvirt_connect_num_of_nwfilters(VALUE c)
* call-seq:
* conn.list_nwfilters -> list
*
- * Call virConnectListNWFilters[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListNWFilters]
+ * Call virConnectListNWFilters[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virConnectListNWFilters]
* to retrieve a list of network filter names on this connection.
*/
static VALUE libvirt_connect_list_nwfilters(VALUE c)
@@ -1590,7 +1604,7 @@ static VALUE libvirt_connect_list_nwfilters(VALUE c)
* call-seq:
* conn.lookup_nwfilter_by_name(name) -> Libvirt::NWFilter
*
- * Call virNWFilterLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterLookupByName]
+ * Call virNWFilterLookupByName[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterLookupByName]
* to retrieve a network filter object by name.
*/
static VALUE libvirt_connect_lookup_nwfilter_by_name(VALUE c, VALUE name)
@@ -1610,7 +1624,7 @@ static VALUE libvirt_connect_lookup_nwfilter_by_name(VALUE c, VALUE name)
* call-seq:
* conn.lookup_nwfilter_by_uuid(uuid) -> Libvirt::NWFilter
*
- * Call virNWFilterLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterLookupByUUIDString]
+ * Call virNWFilterLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterLookupByUUIDString]
* to retrieve a network filter object by UUID.
*/
static VALUE libvirt_connect_lookup_nwfilter_by_uuid(VALUE c, VALUE uuid)
@@ -1630,7 +1644,7 @@ static VALUE libvirt_connect_lookup_nwfilter_by_uuid(VALUE c, VALUE uuid)
* call-seq:
* conn.define_nwfilter_xml(xml) -> Libvirt::NWFilter
*
- * Call virNWFilterDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterDefineXML]
+ * Call virNWFilterDefineXML[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterDefineXML]
* to define a new network filter from xml.
*/
static VALUE libvirt_connect_define_nwfilter_xml(VALUE c, VALUE xml)
@@ -1653,7 +1667,7 @@ static VALUE libvirt_connect_define_nwfilter_xml(VALUE c, VALUE xml)
* call-seq:
* conn.num_of_secrets -> Fixnum
*
- * Call virConnectNumOfSecrets[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfSecrets]
+ * Call virConnectNumOfSecrets[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virConnectNumOfSecrets]
* to retrieve the number of secrets on this connection.
*/
static VALUE libvirt_connect_num_of_secrets(VALUE c)
@@ -1665,7 +1679,7 @@ static VALUE libvirt_connect_num_of_secrets(VALUE c)
* call-seq:
* conn.list_secrets -> list
*
- * Call virConnectListSecrets[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListSecrets]
+ * Call virConnectListSecrets[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virConnectListSecrets]
* to retrieve a list of secret UUIDs on this connection.
*/
static VALUE libvirt_connect_list_secrets(VALUE c)
@@ -1677,7 +1691,7 @@ static VALUE libvirt_connect_list_secrets(VALUE c)
* call-seq:
* conn.lookup_secret_by_uuid(uuid) -> Libvirt::Secret
*
- * Call virSecretLookupByUUID[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretLookupByUUID]
+ * Call virSecretLookupByUUID[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretLookupByUUID]
* to retrieve a network object from uuid.
*/
static VALUE libvirt_connect_lookup_secret_by_uuid(VALUE c, VALUE uuid)
@@ -1697,7 +1711,7 @@ static VALUE libvirt_connect_lookup_secret_by_uuid(VALUE c, VALUE uuid)
* call-seq:
* conn.lookup_secret_by_usage(usagetype, usageID) -> Libvirt::Secret
*
- * Call virSecretLookupByUsage[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretLookupByUsage]
+ * Call virSecretLookupByUsage[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretLookupByUsage]
* to retrieve a secret by usagetype.
*/
static VALUE libvirt_connect_lookup_secret_by_usage(VALUE c, VALUE usagetype,
@@ -1719,7 +1733,7 @@ static VALUE libvirt_connect_lookup_secret_by_usage(VALUE c, VALUE usagetype,
* call-seq:
* conn.define_secret_xml(xml, flags=0) -> Libvirt::Secret
*
- * Call virSecretDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretDefineXML]
+ * Call virSecretDefineXML[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretDefineXML]
* to define a new secret from xml.
*/
static VALUE libvirt_connect_define_secret_xml(int argc, VALUE *argv, VALUE c)
@@ -1748,7 +1762,7 @@ VALUE pool_new(virStoragePoolPtr n, VALUE conn);
* call-seq:
* conn.list_storage_pools -> list
*
- * Call virConnectListStoragePools[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListStoragePools]
+ * Call virConnectListStoragePools[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virConnectListStoragePools]
* to retrieve a list of active storage pool names on this connection.
*/
static VALUE libvirt_connect_list_storage_pools(VALUE c)
@@ -1760,7 +1774,7 @@ static VALUE libvirt_connect_list_storage_pools(VALUE c)
* call-seq:
* conn.num_of_storage_pools -> Fixnum
*
- * Call virConnectNumOfStoragePools[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfStoragePools]
+ * Call virConnectNumOfStoragePools[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virConnectNumOfStoragePools]
* to retrieve the number of active storage pools on this connection.
*/
static VALUE libvirt_connect_num_of_storage_pools(VALUE c)
@@ -1772,7 +1786,7 @@ static VALUE libvirt_connect_num_of_storage_pools(VALUE c)
* call-seq:
* conn.list_defined_storage_pools -> list
*
- * Call virConnectListDefinedStoragePools[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListDefinedStoragePools]
+ * Call virConnectListDefinedStoragePools[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virConnectListDefinedStoragePools]
* to retrieve a list of inactive storage pool names on this connection.
*/
static VALUE libvirt_connect_list_defined_storage_pools(VALUE c)
@@ -1784,7 +1798,7 @@ static VALUE libvirt_connect_list_defined_storage_pools(VALUE c)
* call-seq:
* conn.num_of_defined_storage_pools -> Fixnum
*
- * Call virConnectNumOfDefinedStoragePools[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfDefinedStoragePools]
+ * Call virConnectNumOfDefinedStoragePools[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virConnectNumOfDefinedStoragePools]
* to retrieve the number of inactive storage pools on this connection.
*/
static VALUE libvirt_connect_num_of_defined_storage_pools(VALUE c)
@@ -1796,7 +1810,7 @@ static VALUE libvirt_connect_num_of_defined_storage_pools(VALUE c)
* call-seq:
* conn.lookup_storage_pool_by_name(name) -> Libvirt::StoragePool
*
- * Call virStoragePoolLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolLookupByName]
+ * Call virStoragePoolLookupByName[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolLookupByName]
* to retrieve a storage pool object by name.
*/
static VALUE libvirt_connect_lookup_pool_by_name(VALUE c, VALUE name)
@@ -1816,7 +1830,7 @@ static VALUE libvirt_connect_lookup_pool_by_name(VALUE c, VALUE name)
* call-seq:
* conn.lookup_storage_pool_by_uuid(uuid) -> Libvirt::StoragePool
*
- * Call virStoragePoolLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolLookupByUUIDString]
+ * Call virStoragePoolLookupByUUIDString[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolLookupByUUIDString]
* to retrieve a storage pool object by uuid.
*/
static VALUE libvirt_connect_lookup_pool_by_uuid(VALUE c, VALUE uuid)
@@ -1836,7 +1850,7 @@ static VALUE libvirt_connect_lookup_pool_by_uuid(VALUE c, VALUE uuid)
* call-seq:
* conn.create_storage_pool_xml(xml, flags=0) -> Libvirt::StoragePool
*
- * Call virStoragePoolCreateXML[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolCreateXML]
+ * Call virStoragePoolCreateXML[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolCreateXML]
* to start a new transient storage pool from xml.
*/
static VALUE libvirt_connect_create_pool_xml(int argc, VALUE *argv, VALUE c)
@@ -1860,7 +1874,7 @@ static VALUE libvirt_connect_create_pool_xml(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.define_storage_pool_xml(xml, flags=0) -> Libvirt::StoragePool
*
- * Call virStoragePoolDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolDefineXML]
+ * Call virStoragePoolDefineXML[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolDefineXML]
* to define a permanent storage pool from xml.
*/
static VALUE libvirt_connect_define_pool_xml(int argc, VALUE *argv, VALUE c)
@@ -1884,7 +1898,7 @@ static VALUE libvirt_connect_define_pool_xml(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.discover_storage_pool_sources(type, srcSpec=nil, flags=0) -> String
*
- * Call virConnectFindStoragePoolSources[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectFindStoragePoolSources]
+ * Call virConnectFindStoragePoolSources[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virConnectFindStoragePoolSources]
* to find the storage pool sources corresponding to type.
*/
static VALUE libvirt_connect_find_storage_pool_sources(int argc, VALUE *argv,
@@ -1908,7 +1922,7 @@ static VALUE libvirt_connect_find_storage_pool_sources(int argc, VALUE *argv,
* call-seq:
* conn.sys_info(flags=0) -> String
*
- * Call virConnectGetSysinfo[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetSysinfo]
+ * Call virConnectGetSysinfo[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetSysinfo]
* to get machine-specific information about the hypervisor. This may include
* data such as the host UUID, the BIOS version, etc.
*/
@@ -1931,7 +1945,7 @@ static VALUE libvirt_connect_sys_info(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.stream(flags=0) -> Libvirt::Stream
*
- * Call virStreamNew[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamNew]
+ * Call virStreamNew[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamNew]
* to create a new stream.
*/
static VALUE libvirt_connect_stream(int argc, VALUE *argv, VALUE c)
@@ -1956,7 +1970,7 @@ static VALUE libvirt_connect_stream(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.interface_change_begin(flags=0) -> nil
*
- * Call virInterfaceChangeBegin[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceChangeBegin]
+ * Call virInterfaceChangeBegin[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceChangeBegin]
* to create a restore point for interface changes. Once changes have been
* made, conn.interface_change_commit can be used to commit the result or
* conn.interface_change_rollback can be used to rollback to this restore point.
@@ -1978,7 +1992,7 @@ static VALUE libvirt_connect_interface_change_begin(int argc, VALUE *argv,
* call-seq:
* conn.interface_change_commit(flags=0) -> nil
*
- * Call virInterfaceChangeCommit[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceChangeCommit]
+ * Call virInterfaceChangeCommit[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceChangeCommit]
* to commit the interface changes since the last conn.interface_change_begin.
*/
static VALUE libvirt_connect_interface_change_commit(int argc, VALUE *argv,
@@ -1998,7 +2012,7 @@ static VALUE libvirt_connect_interface_change_commit(int argc, VALUE *argv,
* call-seq:
* conn.interface_change_rollback(flags=0) -> nil
*
- * Call virInterfaceChangeRollback[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceChangeRollback]
+ * Call virInterfaceChangeRollback[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceChangeRollback]
* to rollback to the restore point saved by conn.interface_change_begin.
*/
static VALUE libvirt_connect_interface_change_rollback(int argc, VALUE *argv,
@@ -2055,7 +2069,7 @@ static const char *cpu_stats_get(VALUE d, unsigned int flags, void *voidparams,
* call-seq:
* conn.node_cpu_stats(cpuNum=-1, flags=0) -> Hash
*
- * Call virNodeGetCPUStats[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetCPUStats]
+ * Call virNodeGetCPUStats[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetCPUStats]
* to retrieve cpu statistics from the virtualization host.
*/
static VALUE libvirt_connect_node_cpu_stats(int argc, VALUE *argv, VALUE c)
@@ -2115,7 +2129,7 @@ static const char *memory_stats_get(VALUE d, unsigned int flags,
* call-seq:
* conn.node_memory_stats(cellNum=-1, flags=0) -> Hash
*
- * Call virNodeGetMemoryStats[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetMemoryStats]
+ * Call virNodeGetMemoryStats[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetMemoryStats]
* to retrieve memory statistics from the virtualization host.
*/
static VALUE libvirt_connect_node_memory_stats(int argc, VALUE *argv, VALUE c)
@@ -2139,7 +2153,7 @@ static VALUE libvirt_connect_node_memory_stats(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.save_image_xml_desc(filename, flags=0) -> String
*
- * Call virDomainSaveImageGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSaveImageGetXMLDesc]
+ * Call virDomainSaveImageGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSaveImageGetXMLDesc]
* to get the XML corresponding to a save file.
*/
static VALUE libvirt_connect_save_image_xml_desc(int argc, VALUE *argv, VALUE c)
@@ -2159,7 +2173,7 @@ static VALUE libvirt_connect_save_image_xml_desc(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.define_save_image_xml(filename, newxml, flags=0) -> nil
*
- * Call virDomainSaveImageDefineXML[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSaveImageDefineXML]
+ * Call virDomainSaveImageDefineXML[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSaveImageDefineXML]
* to define new XML for a saved image.
*/
static VALUE libvirt_connect_define_save_image_xml(int argc, VALUE *argv,
@@ -2183,7 +2197,7 @@ static VALUE libvirt_connect_define_save_image_xml(int argc, VALUE *argv,
* call-seq:
* conn.node_suspend_for_duration(target, duration, flags=0) -> nil
*
- * Call virNodeSuspendForDuration[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeSuspendForDuration]
+ * Call virNodeSuspendForDuration[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeSuspendForDuration]
* to suspend the hypervisor for the specified duration.
*/
static VALUE libvirt_connect_node_suspend_for_duration(int argc, VALUE *argv,
@@ -2242,7 +2256,7 @@ static const char *node_memory_set(VALUE d, unsigned int flags,
* call-seq:
* conn.node_memory_parameters(flags=0) -> Hash
*
- * Call virNodeGetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetMemoryParameters]
+ * Call virNodeGetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetMemoryParameters]
* to get information about memory on the host node.
*/
static VALUE libvirt_connect_node_memory_parameters(int argc, VALUE *argv,
@@ -2275,7 +2289,7 @@ static struct ruby_libvirt_typed_param memory_allowed[] = {
* call-seq:
* conn.node_memory_parameters = Hash,flags=0
*
- * Call virNodeSetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeSetMemoryParameters]
+ * Call virNodeSetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeSetMemoryParameters]
* to set the memory parameters for this host node.
*/
static VALUE libvirt_connect_node_memory_parameters_equal(VALUE c, VALUE input)
@@ -2313,7 +2327,7 @@ static VALUE cpu_map_field_to_value(VALUE input)
* call-seq:
* conn.node_cpu_map -> Hash
*
- * Call virNodeGetCPUMap[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetCPUMap]
+ * Call virNodeGetCPUMap[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetCPUMap]
* to get a map of online host CPUs.
*/
static VALUE libvirt_connect_node_cpu_map(int argc, VALUE *argv, VALUE c)
@@ -2355,7 +2369,7 @@ static VALUE libvirt_connect_node_cpu_map(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.set_keepalive(interval, count) -> Fixnum
*
- * Call virConnectSetKeepAlive[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectSetKeepAlive]
+ * Call virConnectSetKeepAlive[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectSetKeepAlive]
* to start sending keepalive messages. Deprecated; use conn.keepalive=
* instead.
*/
@@ -2371,7 +2385,7 @@ static VALUE libvirt_connect_set_keepalive(VALUE c, VALUE interval, VALUE count)
* call-seq:
* conn.keepalive = interval,count
*
- * Call virConnectSetKeepAlive[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectSetKeepAlive]
+ * Call virConnectSetKeepAlive[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectSetKeepAlive]
* to start sending keepalive messages.
*/
static VALUE libvirt_connect_keepalive_equal(VALUE c, VALUE in)
@@ -2400,7 +2414,7 @@ static VALUE libvirt_connect_keepalive_equal(VALUE c, VALUE in)
* call-seq:
* conn.list_all_domains(flags=0) -> Array
*
- * Call virConnectListAllDomains[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllDomains]
+ * Call virConnectListAllDomains[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectListAllDomains]
* to get an array of domain objects for all domains.
*/
static VALUE libvirt_connect_list_all_domains(int argc, VALUE *argv, VALUE c)
@@ -2417,7 +2431,7 @@ static VALUE libvirt_connect_list_all_domains(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.list_all_networks(flags=0) -> Array
*
- * Call virConnectListAllNetworks[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllNetworks]
+ * Call virConnectListAllNetworks[http://www.libvirt.org/html/libvirt-libvirt-network.html#virConnectListAllNetworks]
* to get an array of network objects for all networks.
*/
static VALUE libvirt_connect_list_all_networks(int argc, VALUE *argv, VALUE c)
@@ -2435,7 +2449,7 @@ static VALUE libvirt_connect_list_all_networks(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.list_all_interfaces(flags=0) -> Array
*
- * Call virConnectListAllInterfaces[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllInterfaces]
+ * Call virConnectListAllInterfaces[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virConnectListAllInterfaces]
* to get an array of interface objects for all interfaces.
*/
static VALUE libvirt_connect_list_all_interfaces(int argc, VALUE *argv, VALUE c)
@@ -2453,7 +2467,7 @@ static VALUE libvirt_connect_list_all_interfaces(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.list_all_secrets(flags=0) -> Array
*
- * Call virConnectListAllSecrets[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllSecrets]
+ * Call virConnectListAllSecrets[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virConnectListAllSecrets]
* to get an array of secret objects for all secrets.
*/
static VALUE libvirt_connect_list_all_secrets(int argc, VALUE *argv, VALUE c)
@@ -2470,7 +2484,7 @@ static VALUE libvirt_connect_list_all_secrets(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.list_all_nodedevices(flags=0) -> Array
*
- * Call virConnectListAllNodeDevices[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllNodeDevices]
+ * Call virConnectListAllNodeDevices[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virConnectListAllNodeDevices]
* to get an array of nodedevice objects for all nodedevices.
*/
static VALUE libvirt_connect_list_all_nodedevices(int argc, VALUE *argv,
@@ -2489,7 +2503,7 @@ static VALUE libvirt_connect_list_all_nodedevices(int argc, VALUE *argv,
* call-seq:
* conn.list_all_storage_pools(flags=0) -> Array
*
- * Call virConnectListAllStoragePools[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllStoragePools]
+ * Call virConnectListAllStoragePools[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virConnectListAllStoragePools]
* to get an array of storage pool objects for all storage pools.
*/
static VALUE libvirt_connect_list_all_storage_pools(int argc, VALUE *argv,
@@ -2507,7 +2521,7 @@ static VALUE libvirt_connect_list_all_storage_pools(int argc, VALUE *argv,
* call-seq:
* conn.list_all_nwfilters(flags=0) -> Array
*
- * Call virConnectListAllNWFilters[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListAllNWFilters]
+ * Call virConnectListAllNWFilters[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virConnectListAllNWFilters]
* to get an array of nwfilters for all nwfilter objects.
*/
static VALUE libvirt_connect_list_all_nwfilters(int argc, VALUE *argv, VALUE c)
@@ -2525,7 +2539,7 @@ static VALUE libvirt_connect_list_all_nwfilters(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.alive? -> [True|False]
*
- * Call virConnectIsAlive[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectIsAlive]
+ * Call virConnectIsAlive[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectIsAlive]
* to determine if the connection is alive.
*/
static VALUE libvirt_connect_alive_p(VALUE c)
@@ -2541,7 +2555,7 @@ static VALUE libvirt_connect_alive_p(VALUE c)
* call-seq:
* conn.create_domain_xml_with_files(xml, fds=nil, flags=0) -> Libvirt::Domain
*
- * Call virDomainCreateXMLWithFiles[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCreateXMLWithFiles]
+ * Call virDomainCreateXMLWithFiles[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCreateXMLWithFiles]
* to launch a new guest domain with a set of open file descriptors.
*/
static VALUE libvirt_connect_create_domain_xml_with_files(int argc, VALUE *argv,
@@ -2588,7 +2602,7 @@ static VALUE libvirt_connect_create_domain_xml_with_files(int argc, VALUE *argv,
* call-seq:
* conn.qemu_attach(pid, flags=0) -> Libvirt::Domain
*
- * Call virDomainQemuAttach[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainQemuAttach]
+ * Call virDomainQemuAttach
* to attach to the Qemu process pid.
*/
static VALUE libvirt_connect_qemu_attach(int argc, VALUE *argv, VALUE c)
@@ -2612,7 +2626,7 @@ static VALUE libvirt_connect_qemu_attach(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.cpu_model_names(arch, flags=0) -> Array
*
- * Call virConnectGetCPUModelNames[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetCPUModelNames]
+ * Call virConnectGetCPUModelNames[http://www.libvirt.org/html/libvirt-libvirt-host.html#virConnectGetCPUModelNames]
* to get an array of CPU model names.
*/
static VALUE libvirt_connect_cpu_model_names(int argc, VALUE *argv, VALUE c)
@@ -2669,7 +2683,7 @@ error:
* call-seq:
* conn.node_alloc_pages(page_arr, cells=nil, flags=0) -> Fixnum
*
- * Call virNodeAllocPages[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeAllocPages]
+ * Call virNodeAllocPages[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeAllocPages]
* to reserve huge pages in the system pool.
*/
static VALUE libvirt_connect_node_alloc_pages(int argc, VALUE *argv, VALUE c)
@@ -2735,7 +2749,7 @@ static VALUE libvirt_connect_node_alloc_pages(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.domain_capabilities(emulatorbin, arch, machine, virttype, flags=0) -> String
*
- * Call virNodeAllocPages[http://www.libvirt.org/html/libvirt-libvirt.html#virConnectGetDomainCapabilities]
+ * Call virConnectGetDomainCapabilities[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virConnectGetDomainCapabilities]
* to get the capabilities of the underlying emulator.
*/
static VALUE libvirt_connect_domain_capabilities(int argc, VALUE *argv, VALUE c)
@@ -2761,7 +2775,7 @@ static VALUE libvirt_connect_domain_capabilities(int argc, VALUE *argv, VALUE c)
* call-seq:
* conn.node_free_pages(pages, cells, flags=0) -> Hash
*
- * Call virNodeGetFreePages[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeGetFreePages]
+ * Call virNodeGetFreePages[http://www.libvirt.org/html/libvirt-libvirt-host.html#virNodeGetFreePages]
* to query the host system on free pages of specified size.
*/
static VALUE libvirt_connect_node_free_pages(int argc, VALUE *argv, VALUE c)
@@ -3108,8 +3122,12 @@ void ruby_libvirt_connect_init(void)
libvirt_connect_lookup_domain_by_id, 1);
rb_define_method(c_connect, "lookup_domain_by_uuid",
libvirt_connect_lookup_domain_by_uuid, 1);
+#if HAVE_CONST_VIR_DOMAIN_DEFINE_VALIDATE
+ rb_define_const(c_connect, "DOMAIN_DEFINE_VALIDATE",
+ INT2NUM(VIR_DOMAIN_DEFINE_VALIDATE));
+#endif
rb_define_method(c_connect, "define_domain_xml",
- libvirt_connect_define_domain_xml, 1);
+ libvirt_connect_define_domain_xml, -1);
#if HAVE_VIRCONNECTDOMAINXMLFROMNATIVE
rb_define_method(c_connect, "domain_xml_from_native",
diff --git a/ext/libvirt/domain.c b/ext/libvirt/domain.c
index 8961467..7812450 100644
--- a/ext/libvirt/domain.c
+++ b/ext/libvirt/domain.c
@@ -2,7 +2,7 @@
* domain.c: virDomain methods
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013,2014 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -129,7 +129,7 @@ static void domain_input_to_fixnum_and_flags(VALUE in, VALUE *hash, VALUE *flags
* call-seq:
* dom.migrate(dconn, flags=0, dname=nil, uri=nil, bandwidth=0) -> Libvirt::Domain
*
- * Call virDomainMigrate[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrate]
+ * Call virDomainMigrate[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrate]
* to migrate a domain from the host on this connection to the connection
* referenced in dconn.
*/
@@ -159,7 +159,7 @@ static VALUE libvirt_domain_migrate(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.migrate_to_uri(duri, flags=0, dname=nil, bandwidth=0) -> nil
*
- * Call virDomainMigrateToURI[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateToURI]
+ * Call virDomainMigrateToURI[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateToURI]
* to migrate a domain from the host on this connection to the host whose
* libvirt URI is duri.
*/
@@ -183,7 +183,7 @@ static VALUE libvirt_domain_migrate_to_uri(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.migrate_set_max_downtime(downtime, flags=0) -> nil
*
- * Call virDomainMigrateSetMaxDowntime[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateSetMaxDowntime]
+ * Call virDomainMigrateSetMaxDowntime[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateSetMaxDowntime]
* to set the maximum downtime desired for live migration. Deprecated; use
* dom.migrate_max_downtime= instead.
*/
@@ -205,7 +205,7 @@ static VALUE libvirt_domain_migrate_set_max_downtime(int argc, VALUE *argv,
* call-seq:
* dom.migrate_max_downtime = downtime,flags=0
*
- * Call virDomainMigrateSetMaxDowntime[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateSetMaxDowntime]
+ * Call virDomainMigrateSetMaxDowntime[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateSetMaxDowntime]
* to set the maximum downtime desired for live migration.
*/
static VALUE libvirt_domain_migrate_max_downtime_equal(VALUE d, VALUE in)
@@ -227,7 +227,7 @@ static VALUE libvirt_domain_migrate_max_downtime_equal(VALUE d, VALUE in)
* call-seq:
* dom.migrate2(dconn, dxml=nil, flags=0, dname=nil, uri=nil, bandwidth=0) -> Libvirt::Domain
*
- * Call virDomainMigrate2[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrate2]
+ * Call virDomainMigrate2[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrate2]
* to migrate a domain from the host on this connection to the connection
* referenced in dconn.
*/
@@ -257,7 +257,7 @@ static VALUE libvirt_domain_migrate2(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.migrate_to_uri2(duri=nil, migrate_uri=nil, dxml=nil, flags=0, dname=nil, bandwidth=0) -> nil
*
- * Call virDomainMigrateToURI2[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateToURI2]
+ * Call virDomainMigrateToURI2[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateToURI2]
* to migrate a domain from the host on this connection to the host whose
* libvirt URI is duri.
*/
@@ -283,7 +283,7 @@ static VALUE libvirt_domain_migrate_to_uri2(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.migrate_set_max_speed(bandwidth, flags=0) -> nil
*
- * Call virDomainMigrateSetMaxSpeed[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateSetMaxSpeed]
+ * Call virDomainMigrateSetMaxSpeed[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateSetMaxSpeed]
* to set the maximum bandwidth allowed for live migration. Deprecated; use
* dom.migrate_max_speed= instead.
*/
@@ -305,7 +305,7 @@ static VALUE libvirt_domain_migrate_set_max_speed(int argc, VALUE *argv,
* call-seq:
* dom.migrate_max_speed = bandwidth,flags=0
*
- * Call virDomainMigrateSetMaxSpeed[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateSetMaxSpeed]
+ * Call virDomainMigrateSetMaxSpeed[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateSetMaxSpeed]
* to set the maximum bandwidth allowed for live migration.
*/
static VALUE libvirt_domain_migrate_max_speed_equal(VALUE d, VALUE in)
@@ -326,7 +326,7 @@ static VALUE libvirt_domain_migrate_max_speed_equal(VALUE d, VALUE in)
* call-seq:
* dom.shutdown(flags=0) -> nil
*
- * Call virDomainShutdown[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainShutdown]
+ * Call virDomainShutdown[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainShutdown]
* to do a soft shutdown of the domain. The mechanism for doing the shutdown
* is hypervisor specific, and may require software running inside the domain
* to succeed.
@@ -357,7 +357,7 @@ static VALUE libvirt_domain_shutdown(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.reboot(flags=0) -> nil
*
- * Call virDomainReboot[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainReboot]
+ * Call virDomainReboot[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainReboot]
* to do a reboot of the domain.
*/
static VALUE libvirt_domain_reboot(int argc, VALUE *argv, VALUE d)
@@ -375,7 +375,7 @@ static VALUE libvirt_domain_reboot(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.destroy(flags=0) -> nil
*
- * Call virDomainDestroy[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainDestroy]
+ * Call virDomainDestroy[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainDestroy]
* to do a hard power-off of the domain.
*/
static VALUE libvirt_domain_destroy(int argc, VALUE *argv, VALUE d)
@@ -403,7 +403,7 @@ static VALUE libvirt_domain_destroy(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.suspend -> nil
*
- * Call virDomainSuspend[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSuspend]
+ * Call virDomainSuspend[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSuspend]
* to stop the domain from executing. The domain will still continue to
* consume memory, but will not take any CPU time.
*/
@@ -418,7 +418,7 @@ static VALUE libvirt_domain_suspend(VALUE d)
* call-seq:
* dom.resume -> nil
*
- * Call virDomainResume[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainResume]
+ * Call virDomainResume[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainResume]
* to resume a suspended domain. After this call the domain will start
* consuming CPU resources again.
*/
@@ -432,7 +432,7 @@ static VALUE libvirt_domain_resume(VALUE d)
* call-seq:
* dom.save(filename, dxml=nil, flags=0) -> nil
*
- * Call virDomainSave[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSave]
+ * Call virDomainSave[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSave]
* to save the domain state to filename. After this call, the domain will no
* longer be consuming any resources.
*/
@@ -467,7 +467,7 @@ static VALUE libvirt_domain_save(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.managed_save(flags=0) -> nil
*
- * Call virDomainManagedSave[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainManagedSave]
+ * Call virDomainManagedSave[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainManagedSave]
* to do a managed save of the domain. The domain will be saved to a place
* of libvirt's choosing.
*/
@@ -487,7 +487,7 @@ static VALUE libvirt_domain_managed_save(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.has_managed_save?(flags=0) -> [True|False]
*
- * Call virDomainHasManagedSaveImage[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainHasManagedSaveImage]
+ * Call virDomainHasManagedSaveImage[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainHasManagedSaveImage]
* to determine if a particular domain has a managed save image.
*/
static VALUE libvirt_domain_has_managed_save(int argc, VALUE *argv, VALUE d)
@@ -506,7 +506,7 @@ static VALUE libvirt_domain_has_managed_save(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.managed_save_remove(flags=0) -> nil
*
- * Call virDomainManagedSaveRemove[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainManagedSaveRemove]
+ * Call virDomainManagedSaveRemove[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainManagedSaveRemove]
* to remove the managed save image for a domain.
*/
static VALUE libvirt_domain_managed_save_remove(int argc, VALUE *argv, VALUE d)
@@ -526,7 +526,7 @@ static VALUE libvirt_domain_managed_save_remove(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.core_dump(filename, flags=0) -> nil
*
- * Call virDomainCoreDump[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCoreDump]
+ * Call virDomainCoreDump[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCoreDump]
* to do a full memory dump of the domain to filename.
*/
static VALUE libvirt_domain_core_dump(int argc, VALUE *argv, VALUE d)
@@ -546,7 +546,7 @@ static VALUE libvirt_domain_core_dump(int argc, VALUE *argv, VALUE d)
* call-seq:
* Libvirt::Domain::restore(conn, filename) -> nil
*
- * Call virDomainRestore[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainRestore]
+ * Call virDomainRestore[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainRestore]
* to restore the domain from the filename.
*/
static VALUE libvirt_domain_s_restore(VALUE RUBY_LIBVIRT_UNUSED(klass), VALUE c,
@@ -562,7 +562,7 @@ static VALUE libvirt_domain_s_restore(VALUE RUBY_LIBVIRT_UNUSED(klass), VALUE c,
* call-seq:
* dom.info -> Libvirt::Domain::Info
*
- * Call virDomainGetInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetInfo]
+ * Call virDomainGetInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetInfo]
* to retrieve domain information.
*/
static VALUE libvirt_domain_info(VALUE d)
@@ -590,7 +590,7 @@ static VALUE libvirt_domain_info(VALUE d)
* call-seq:
* dom.security_label -> Libvirt::Domain::SecurityLabel
*
- * Call virDomainGetSecurityLabel[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetSecurityLabel]
+ * Call virDomainGetSecurityLabel[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetSecurityLabel]
* to retrieve the security label applied to this domain.
*/
static VALUE libvirt_domain_security_label(VALUE d)
@@ -616,7 +616,7 @@ static VALUE libvirt_domain_security_label(VALUE d)
* call-seq:
* dom.block_stats(path) -> Libvirt::Domain::BlockStats
*
- * Call virDomainBlockStats[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockStats]
+ * Call virDomainBlockStats[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockStats]
* to retrieve statistics about domain block device path.
*/
static VALUE libvirt_domain_block_stats(VALUE d, VALUE path)
@@ -645,7 +645,7 @@ static VALUE libvirt_domain_block_stats(VALUE d, VALUE path)
* call-seq:
* dom.memory_stats(flags=0) -> [ Libvirt::Domain::MemoryStats ]
*
- * Call virDomainMemoryStats[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMemoryStats]
+ * Call virDomainMemoryStats[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMemoryStats]
* to retrieve statistics about the amount of memory consumed by a domain.
*/
static VALUE libvirt_domain_memory_stats(int argc, VALUE *argv, VALUE d)
@@ -689,7 +689,7 @@ static VALUE libvirt_domain_memory_stats(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.blockinfo(path, flags=0) -> Libvirt::Domain::BlockInfo
*
- * Call virDomainGetBlockInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetBlockInfo]
+ * Call virDomainGetBlockInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetBlockInfo]
* to retrieve information about the backing file path for the domain.
*/
static VALUE libvirt_domain_block_info(int argc, VALUE *argv, VALUE d)
@@ -720,7 +720,7 @@ static VALUE libvirt_domain_block_info(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.block_peek(path, offset, size, flags=0) -> String
*
- * Call virDomainBlockPeek[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockPeek]
+ * Call virDomainBlockPeek[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockPeek]
* to read size number of bytes, starting at offset offset from domain backing
* file path. Due to limitations of the libvirt remote protocol, the user
* should never request more than 64k bytes.
@@ -750,7 +750,7 @@ static VALUE libvirt_domain_block_peek(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.memory_peek(start, size, flags=Libvirt::Domain::MEMORY_VIRTUAL) -> String
*
- * Call virDomainMemoryPeek[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMemoryPeek]
+ * Call virDomainMemoryPeek[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMemoryPeek]
* to read size number of bytes from offset start from the domain memory.
* Due to limitations of the libvirt remote protocol, the user
* should never request more than 64k bytes.
@@ -781,7 +781,7 @@ static VALUE libvirt_domain_memory_peek(int argc, VALUE *argv, VALUE d)
/* call-seq:
* dom.vcpus -> [ Libvirt::Domain::VCPUInfo ]
*
- * Call virDomainGetVcpus[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetVcpus]
+ * Call virDomainGetVcpus[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetVcpus]
* to retrieve detailed information about the state of a domain's virtual CPUs.
*/
static VALUE libvirt_domain_vcpus(VALUE d)
@@ -865,7 +865,7 @@ static VALUE libvirt_domain_vcpus(VALUE d)
* call-seq:
* dom.active? -> [true|false]
*
- * Call virDomainIsActive[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainIsActive]
+ * Call virDomainIsActive[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainIsActive]
* to determine if this domain is currently active.
*/
static VALUE libvirt_domain_active_p(VALUE d)
@@ -881,7 +881,7 @@ static VALUE libvirt_domain_active_p(VALUE d)
* call-seq:
* dom.persistent? -> [true|false]
*
- * Call virDomainIsPersistent[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainIsPersistent]
+ * Call virDomainIsPersistent[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainIsPersistent]
* to determine if this is a persistent domain.
*/
static VALUE libvirt_domain_persistent_p(VALUE d)
@@ -896,7 +896,7 @@ static VALUE libvirt_domain_persistent_p(VALUE d)
* call-seq:
* dom.ifinfo(if) -> Libvirt::Domain::IfInfo
*
- * Call virDomainInterfaceStats[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainInterfaceStats]
+ * Call virDomainInterfaceStats[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainInterfaceStats]
* to retrieve statistics about domain interface if.
*/
static VALUE libvirt_domain_if_stats(VALUE d, VALUE sif)
@@ -930,7 +930,7 @@ static VALUE libvirt_domain_if_stats(VALUE d, VALUE sif)
* call-seq:
* dom.name -> String
*
- * Call virDomainGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetName]
+ * Call virDomainGetName[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetName]
* to retrieve the name of this domain.
*/
static VALUE libvirt_domain_name(VALUE d)
@@ -944,7 +944,7 @@ static VALUE libvirt_domain_name(VALUE d)
* call-seq:
* dom.id -> Fixnum
*
- * Call virDomainGetID[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetID]
+ * Call virDomainGetID[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetID]
* to retrieve the ID of this domain. If the domain isn't running, this will
* be -1.
*/
@@ -969,7 +969,7 @@ static VALUE libvirt_domain_id(VALUE d)
* call-seq:
* dom.uuid -> String
*
- * Call virDomainGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetUUIDString]
+ * Call virDomainGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetUUIDString]
* to retrieve the UUID of this domain.
*/
static VALUE libvirt_domain_uuid(VALUE d)
@@ -983,7 +983,7 @@ static VALUE libvirt_domain_uuid(VALUE d)
* call-seq:
* dom.os_type -> String
*
- * Call virDomainGetOSType[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetOSType]
+ * Call virDomainGetOSType[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetOSType]
* to retrieve the os_type of this domain. In libvirt terms, os_type determines
* whether this domain is fully virtualized, paravirtualized, or a container.
*/
@@ -998,7 +998,7 @@ static VALUE libvirt_domain_os_type(VALUE d)
* call-seq:
* dom.max_memory -> Fixnum
*
- * Call virDomainGetMaxMemory[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetMaxMemory]
+ * Call virDomainGetMaxMemory[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetMaxMemory]
* to retrieve the maximum amount of memory this domain is allowed to access.
* Note that the current amount of memory this domain is allowed to access may
* be different (see dom.memory_set).
@@ -1019,7 +1019,7 @@ static VALUE libvirt_domain_max_memory(VALUE d)
* call-seq:
* dom.max_memory = Fixnum
*
- * Call virDomainSetMaxMemory[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetMaxMemory]
+ * Call virDomainSetMaxMemory[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetMaxMemory]
* to set the maximum amount of memory (in kilobytes) this domain should be
* allowed to access.
*/
@@ -1040,7 +1040,7 @@ static VALUE libvirt_domain_max_memory_equal(VALUE d, VALUE max_memory)
* call-seq:
* dom.memory = Fixnum,flags=0
*
- * Call virDomainSetMemory[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetMemory]
+ * Call virDomainSetMemory[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetMemory]
* to set the amount of memory (in kilobytes) this domain should currently
* have. Note this will only succeed if both the hypervisor and the domain on
* this connection support ballooning.
@@ -1072,7 +1072,7 @@ static VALUE libvirt_domain_memory_equal(VALUE d, VALUE in)
* call-seq:
* dom.max_vcpus -> Fixnum
*
- * Call virDomainGetMaxVcpus[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetMaxVcpus]
+ * Call virDomainGetMaxVcpus[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetMaxVcpus]
* to retrieve the maximum number of virtual CPUs this domain can use.
*/
static VALUE libvirt_domain_max_vcpus(VALUE d)
@@ -1086,7 +1086,7 @@ static VALUE libvirt_domain_max_vcpus(VALUE d)
/* call-seq:
* dom.num_vcpus(flags) -> Fixnum
*
- * Call virDomainGetVcpusFlags[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetVcpusFlags]
+ * Call virDomainGetVcpusFlags[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetVcpusFlags]
* to retrieve the number of virtual CPUs assigned to this domain.
*/
static VALUE libvirt_domain_num_vcpus(VALUE d, VALUE flags)
@@ -1102,7 +1102,7 @@ static VALUE libvirt_domain_num_vcpus(VALUE d, VALUE flags)
* call-seq:
* dom.vcpus = Fixnum,flags=0
*
- * Call virDomainSetVcpus[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetVcpus]
+ * Call virDomainSetVcpus[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetVcpus]
* to set the current number of virtual CPUs this domain should have. Note
* that this will only work if both the hypervisor and domain on this
* connection support virtual CPU hotplug/hot-unplug.
@@ -1152,7 +1152,7 @@ static VALUE libvirt_domain_vcpus_equal(VALUE d, VALUE in)
* dom.vcpus_flags = Fixnum,flags=0
*
- * Call virDomainSetVcpusFlags[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetVcpusFlags]
+ * Call virDomainSetVcpusFlags[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetVcpusFlags]
* to set the current number of virtual CPUs this domain should have. The
* flags parameter controls whether the change is made to the running domain
* the domain configuration, or both, and must not be 0. Deprecated;
@@ -1175,7 +1175,7 @@ static VALUE libvirt_domain_vcpus_flags_equal(VALUE d, VALUE in)
* call-seq:
* dom.pin_vcpu(vcpu, cpulist, flags=0) -> nil
*
- * Call virDomainPinVcpu[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainPinVcpu]
+ * Call virDomainPinVcpu[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainPinVcpu]
* to pin a particular virtual CPU to a range of physical processors. The
* cpulist should be an array of Fixnums representing the physical processors
* this virtual CPU should be allowed to be scheduled on.
@@ -1224,7 +1224,7 @@ static VALUE libvirt_domain_pin_vcpu(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.xml_desc(flags=0) -> String
*
- * Call virDomainGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetXMLDesc]
+ * Call virDomainGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetXMLDesc]
* to retrieve the XML describing this domain.
*/
static VALUE libvirt_domain_xml_desc(int argc, VALUE *argv, VALUE d)
@@ -1243,7 +1243,7 @@ static VALUE libvirt_domain_xml_desc(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.undefine(flags=0) -> nil
*
- * Call virDomainUndefine[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainUndefine]
+ * Call virDomainUndefine[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainUndefine]
* to undefine the domain. After this call, the domain object is no longer
* valid.
*/
@@ -1273,7 +1273,7 @@ static VALUE libvirt_domain_undefine(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.create(flags=0) -> nil
*
- * Call virDomainCreate[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCreate]
+ * Call virDomainCreate[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCreate]
* to start an already defined domain.
*/
static VALUE libvirt_domain_create(int argc, VALUE *argv, VALUE d)
@@ -1300,7 +1300,7 @@ static VALUE libvirt_domain_create(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.autostart -> [true|false]
*
- * Call virDomainGetAutostart[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetAutostart]
+ * Call virDomainGetAutostart[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetAutostart]
* to find out the state of the autostart flag for a domain.
*/
static VALUE libvirt_domain_autostart(VALUE d)
@@ -1318,7 +1318,7 @@ static VALUE libvirt_domain_autostart(VALUE d)
* call-seq:
* dom.autostart = [true|false]
*
- * Call virDomainSetAutostart[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetAutostart]
+ * Call virDomainSetAutostart[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetAutostart]
* to make this domain autostart when libvirtd starts up.
*/
static VALUE libvirt_domain_autostart_equal(VALUE d, VALUE autostart)
@@ -1338,7 +1338,7 @@ static VALUE libvirt_domain_autostart_equal(VALUE d, VALUE autostart)
* call-seq:
* dom.attach_device(device_xml, flags=0) -> nil
*
- * Call virDomainAttachDevice[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainAttachDevice]
+ * Call virDomainAttachDevice[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainAttachDevice]
* to attach the device described by the device_xml to the domain.
*/
static VALUE libvirt_domain_attach_device(int argc, VALUE *argv, VALUE d)
@@ -1368,7 +1368,7 @@ static VALUE libvirt_domain_attach_device(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.detach_device(device_xml, flags=0) -> nil
*
- * Call virDomainDetachDevice[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainDetachDevice]
+ * Call virDomainDetachDevice[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainDetachDevice]
* to detach the device described by the device_xml from the domain.
*/
static VALUE libvirt_domain_detach_device(int argc, VALUE *argv, VALUE d)
@@ -1399,7 +1399,7 @@ static VALUE libvirt_domain_detach_device(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.update_device(device_xml, flags=0) -> nil
*
- * Call virDomainUpdateDeviceFlags[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainUpdateDeviceFlags]
+ * Call virDomainUpdateDeviceFlags[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainUpdateDeviceFlags]
* to update the device described by the device_xml.
*/
static VALUE libvirt_domain_update_device(int argc, VALUE *argv, VALUE d)
@@ -1420,7 +1420,7 @@ static VALUE libvirt_domain_update_device(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.free -> nil
*
- * Call virDomainFree[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainFree]
+ * Call virDomainFree[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainFree]
* to free a domain object.
*/
static VALUE libvirt_domain_free(VALUE d)
@@ -1455,7 +1455,7 @@ static virDomainSnapshotPtr domain_snapshot_get(VALUE d)
* call-seq:
* dom.snapshot_create_xml(snapshot_xml, flags=0) -> Libvirt::Domain::Snapshot
*
- * Call virDomainSnapshotCreateXML[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotCreateXML]
+ * Call virDomainSnapshotCreateXML[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotCreateXML]
* to create a new snapshot based on snapshot_xml.
*/
static VALUE libvirt_domain_snapshot_create_xml(int argc, VALUE *argv, VALUE d)
@@ -1480,7 +1480,7 @@ static VALUE libvirt_domain_snapshot_create_xml(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.num_of_snapshots(flags=0) -> Fixnum
*
- * Call virDomainSnapshotNum[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotNum]
+ * Call virDomainSnapshotNum[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotNum]
* to retrieve the number of available snapshots for this domain.
*/
static VALUE libvirt_domain_num_of_snapshots(int argc, VALUE *argv, VALUE d)
@@ -1499,7 +1499,7 @@ static VALUE libvirt_domain_num_of_snapshots(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.list_snapshots(flags=0) -> list
*
- * Call virDomainSnapshotListNames[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotListNames]
+ * Call virDomainSnapshotListNames[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotListNames]
* to retrieve a list of snapshot names available for this domain.
*/
static VALUE libvirt_domain_list_snapshots(int argc, VALUE *argv, VALUE d)
@@ -1539,7 +1539,7 @@ static VALUE libvirt_domain_list_snapshots(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.lookup_snapshot_by_name(name, flags=0) -> Libvirt::Domain::Snapshot
*
- * Call virDomainSnapshotLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotLookupByName]
+ * Call virDomainSnapshotLookupByName[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotLookupByName]
* to retrieve a snapshot object corresponding to snapshot name.
*/
static VALUE libvirt_domain_lookup_snapshot_by_name(int argc, VALUE *argv,
@@ -1564,7 +1564,7 @@ static VALUE libvirt_domain_lookup_snapshot_by_name(int argc, VALUE *argv,
* call-seq:
* dom.has_current_snapshot?(flags=0) -> [true|false]
*
- * Call virDomainHasCurrentSnapshot[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainHasCurrentSnapshot]
+ * Call virDomainHasCurrentSnapshot[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainHasCurrentSnapshot]
* to find out if this domain has a snapshot active.
*/
static VALUE libvirt_domain_has_current_snapshot_p(int argc, VALUE *argv,
@@ -1584,7 +1584,7 @@ static VALUE libvirt_domain_has_current_snapshot_p(int argc, VALUE *argv,
* call-seq:
* dom.revert_to_snapshot(snapshot_object, flags=0) -> nil
*
- * Call virDomainRevertToSnapshot[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainRevertToSnapshot]
+ * Call virDomainRevertToSnapshot[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainRevertToSnapshot]
* to restore this domain to a previously saved snapshot.
*/
static VALUE libvirt_domain_revert_to_snapshot(int argc, VALUE *argv, VALUE d)
@@ -1603,7 +1603,7 @@ static VALUE libvirt_domain_revert_to_snapshot(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.current_snapshot(flags=0) -> Libvirt::Domain::Snapshot
*
- * Call virDomainCurrentSnapshot[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCurrentSnapshot]
+ * Call virDomainCurrentSnapshot[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCurrentSnapshot]
* to retrieve the current snapshot for this domain (if any).
*/
static VALUE libvirt_domain_current_snapshot(int argc, VALUE *argv, VALUE d)
@@ -1626,7 +1626,7 @@ static VALUE libvirt_domain_current_snapshot(int argc, VALUE *argv, VALUE d)
* call-seq:
* snapshot.xml_desc(flags=0) -> String
*
- * Call virDomainSnapshotGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotGetXMLDesc]
+ * Call virDomainSnapshotGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotGetXMLDesc]
* to retrieve the xml description for this snapshot.
*/
static VALUE libvirt_domain_snapshot_xml_desc(int argc, VALUE *argv, VALUE s)
@@ -1645,7 +1645,7 @@ static VALUE libvirt_domain_snapshot_xml_desc(int argc, VALUE *argv, VALUE s)
* call-seq:
* snapshot.delete(flags=0) -> nil
*
- * Call virDomainSnapshotDelete[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotDelete]
+ * Call virDomainSnapshotDelete[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotDelete]
* to delete this snapshot.
*/
static VALUE libvirt_domain_snapshot_delete(int argc, VALUE *argv, VALUE s)
@@ -1664,7 +1664,7 @@ static VALUE libvirt_domain_snapshot_delete(int argc, VALUE *argv, VALUE s)
* call-seq:
* snapshot.free -> nil
*
- * Call virDomainSnapshotFree[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotFree]
+ * Call virDomainSnapshotFree[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotFree]
* to free up the snapshot object. After this call the snapshot object is
* no longer valid.
*/
@@ -1680,7 +1680,7 @@ static VALUE libvirt_domain_snapshot_free(VALUE s)
* call-seq:
* snapshot.name -> String
*
- * Call virDomainSnapshotGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotGetName]
+ * Call virDomainSnapshotGetName[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotGetName]
* to get the name associated with a snapshot.
*/
static VALUE libvirt_domain_snapshot_name(VALUE s)
@@ -1697,7 +1697,7 @@ static VALUE libvirt_domain_snapshot_name(VALUE s)
* call-seq:
* dom.job_info -> Libvirt::Domain::JobInfo
*
- * Call virDomainGetJobInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetJobInfo]
+ * Call virDomainGetJobInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetJobInfo]
* to retrieve the current state of the running domain job.
*/
static VALUE libvirt_domain_job_info(VALUE d)
@@ -1731,7 +1731,7 @@ static VALUE libvirt_domain_job_info(VALUE d)
* call-seq:
* dom.abort_job -> nil
*
- * Call virDomainAbortJob[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainAbortJob]
+ * Call virDomainAbortJob[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainAbortJob]
* to abort the currently running job on this domain.
*/
static VALUE libvirt_domain_abort_job(VALUE d)
@@ -1766,7 +1766,7 @@ static VALUE create_sched_type_array(VALUE input)
* call-seq:
* dom.scheduler_type -> [type, #params]
*
- * Call virDomainGetSchedulerType[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetSchedulerType]
+ * Call virDomainGetSchedulerType[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetSchedulerType]
* to retrieve the scheduler type used on this domain.
*/
static VALUE libvirt_domain_scheduler_type(VALUE d)
@@ -1816,7 +1816,11 @@ static VALUE libvirt_domain_qemu_monitor_command(int argc, VALUE *argv, VALUE d)
type = virConnectGetType(ruby_libvirt_connect_get(d));
ruby_libvirt_raise_error_if(type == NULL, e_Error, "virConnectGetType",
ruby_libvirt_connect_get(d));
- if (strcmp(type, "QEMU") != 0) {
+ /* The type != NULL check is actually redundant, since if type was NULL
+ * we would have raised an exception above. It's here to shut clang,
+ * since clang can't tell that we would never reach this.
+ */
+ if (type != NULL && strcmp(type, "QEMU") != 0) {
rb_raise(rb_eTypeError,
"Tried to use virDomainQemuMonitor command on %s connection",
type);
@@ -1844,7 +1848,7 @@ static VALUE libvirt_domain_qemu_monitor_command(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.updated? -> [True|False]
*
- * Call virDomainIsUpdated[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainIsUpdated]
+ * Call virDomainIsUpdated[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainIsUpdated]
* to determine whether the definition for this domain has been updated.
*/
static VALUE libvirt_domain_is_updated(VALUE d)
@@ -1924,7 +1928,7 @@ static const char *scheduler_set(VALUE d, unsigned int flags,
* call-seq:
* dom.scheduler_parameters(flags=0) -> Hash
*
- * Call virDomainGetSchedulerParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetSchedulerParameters]
+ * Call virDomainGetSchedulerParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetSchedulerParameters]
* to retrieve all of the scheduler parameters for this domain. The keys and
* values in the hash that is returned are hypervisor specific.
*/
@@ -1961,7 +1965,7 @@ static struct ruby_libvirt_typed_param domain_scheduler_allowed[] = {
* call-seq:
* dom.scheduler_parameters = Hash
*
- * Call virDomainSetSchedulerParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetSchedulerParameters]
+ * Call virDomainSetSchedulerParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetSchedulerParameters]
* to set the scheduler parameters for this domain. The keys and values in
* the input hash are hypervisor specific. If an empty hash is given, no
* changes are made (and no error is raised).
@@ -2032,7 +2036,7 @@ static const char *memory_set(VALUE d, unsigned int flags,
* call-seq:
* dom.memory_parameters(flags=0) -> Hash
*
- * Call virDomainGetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetMemoryParameters]
+ * Call virDomainGetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetMemoryParameters]
* to retrieve all of the memory parameters for this domain. The keys and
* values in the hash that is returned are hypervisor specific.
*/
@@ -2058,7 +2062,7 @@ static struct ruby_libvirt_typed_param domain_memory_allowed[] = {
* call-seq:
* dom.memory_parameters = Hash,flags=0
*
- * Call virDomainSetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetMemoryParameters]
+ * Call virDomainSetMemoryParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetMemoryParameters]
* to set the memory parameters for this domain. The keys and values in
* the input hash are hypervisor specific.
*/
@@ -2129,7 +2133,7 @@ static const char *blkio_set(VALUE d, unsigned int flags,
* call-seq:
* dom.blkio_parameters(flags=0) -> Hash
*
- * Call virDomainGetBlkioParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetBlkioParameters]
+ * Call virDomainGetBlkioParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetBlkioParameters]
* to retrieve all of the blkio parameters for this domain. The keys and
* values in the hash that is returned are hypervisor specific.
*/
@@ -2153,7 +2157,7 @@ static struct ruby_libvirt_typed_param blkio_allowed[] = {
* call-seq:
* dom.blkio_parameters = Hash,flags=0
*
- * Call virDomainSetBlkioParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetBlkioParameters]
+ * Call virDomainSetBlkioParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetBlkioParameters]
* to set the blkio parameters for this domain. The keys and values in
* the input hash are hypervisor specific.
*/
@@ -2175,7 +2179,7 @@ static VALUE libvirt_domain_blkio_parameters_equal(VALUE d, VALUE in)
* call-seq:
* dom.state(flags=0) -> state, reason
*
- * Call virDomainGetState[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetState]
+ * Call virDomainGetState[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetState]
* to get the current state of the domain.
*/
static VALUE libvirt_domain_state(int argc, VALUE *argv, VALUE d)
@@ -2204,7 +2208,7 @@ static VALUE libvirt_domain_state(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.open_console(device, stream, flags=0) -> nil
*
- * Call virDomainOpenConsole[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainOpenConsole]
+ * Call virDomainOpenConsole[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainOpenConsole]
* to open up a console to device over stream.
*/
static VALUE libvirt_domain_open_console(int argc, VALUE *argv, VALUE d)
@@ -2227,7 +2231,7 @@ static VALUE libvirt_domain_open_console(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.screenshot(stream, screen, flags=0) -> nil
*
- * Call virDomainScreenshot[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainScreenshot]
+ * Call virDomainScreenshot[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainScreenshot]
* to take a screenshot of the domain console as a stream.
*/
static VALUE libvirt_domain_screenshot(int argc, VALUE *argv, VALUE d)
@@ -2250,7 +2254,7 @@ static VALUE libvirt_domain_screenshot(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.inject_nmi(flags=0) -> nil
*
- * Call virDomainInjectNMI[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainInjectNMI]
+ * Call virDomainInjectNMI[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainInjectNMI]
* to send an NMI to the guest.
*/
static VALUE libvirt_domain_inject_nmi(int argc, VALUE *argv, VALUE d)
@@ -2271,7 +2275,7 @@ static VALUE libvirt_domain_inject_nmi(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.control_info(flags=0) -> Libvirt::Domain::ControlInfo
*
- * Call virDomainGetControlInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetControlInfo]
+ * Call virDomainGetControlInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetControlInfo]
* to retrieve domain control interface information.
*/
static VALUE libvirt_domain_control_info(int argc, VALUE *argv, VALUE d)
@@ -2302,7 +2306,7 @@ static VALUE libvirt_domain_control_info(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.send_key(codeset, holdtime, keycodes)
*
- * Call virDomainSendKey[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSendKey]
+ * Call virDomainSendKey[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSendKey]
* to send key(s) to the domain. Keycodes has to be an array of keys to send.
*/
VALUE libvirt_domain_send_key(VALUE d, VALUE codeset, VALUE holdtime,
@@ -2332,7 +2336,7 @@ VALUE libvirt_domain_send_key(VALUE d, VALUE codeset, VALUE holdtime,
* call-seq:
* dom.migrate_max_speed(flags=0) -> Fixnum
*
- * Call virDomainMigrateGetMaxSpeed[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateGetMaxSpeed]
+ * Call virDomainMigrateGetMaxSpeed[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateGetMaxSpeed]
* to retrieve the maximum speed a migration can use.
*/
static VALUE libvirt_domain_migrate_max_speed(int argc, VALUE *argv, VALUE d)
@@ -2358,7 +2362,7 @@ static VALUE libvirt_domain_migrate_max_speed(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.reset(flags=0) -> nil
*
- * Call virDomainReset[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainReset]
+ * Call virDomainReset[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainReset]
* to reset a domain immediately.
*/
static VALUE libvirt_domain_reset(int argc, VALUE *argv, VALUE d)
@@ -2378,7 +2382,7 @@ static VALUE libvirt_domain_reset(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.hostname(flags=0) -> nil
*
- * Call virDomainGetHostname[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetHostname]
+ * Call virDomainGetHostname[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetHostname]
* to get the hostname from a domain.
*/
static VALUE libvirt_domain_hostname(int argc, VALUE *argv, VALUE d)
@@ -2399,7 +2403,7 @@ static VALUE libvirt_domain_hostname(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.metadata(type, uri=nil, flags=0) -> String
*
- * Call virDomainGetMetadata[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetMetadata]
+ * Call virDomainGetMetadata[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetMetadata]
* to get the metadata from a domain.
*/
static VALUE libvirt_domain_metadata(int argc, VALUE *argv, VALUE d)
@@ -2421,7 +2425,7 @@ static VALUE libvirt_domain_metadata(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.metadata = Fixnum,string/nil,key=nil,uri=nil,flags=0 -> nil
*
- * Call virDomainSetMetadata[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetMetadata]
+ * Call virDomainSetMetadata[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetMetadata]
* to set the metadata for a domain.
*/
static VALUE libvirt_domain_metadata_equal(VALUE d, VALUE in)
@@ -2467,7 +2471,7 @@ static VALUE libvirt_domain_metadata_equal(VALUE d, VALUE in)
* call-seq:
* dom.send_process_signal(pid, signum, flags=0) -> nil
*
- * Call virDomainSendProcessSignal[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSendProcessSignal]
+ * Call virDomainSendProcessSignal[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSendProcessSignal]
* to send a signal to a process inside the domain.
*/
static VALUE libvirt_domain_send_process_signal(int argc, VALUE *argv, VALUE d)
@@ -2489,7 +2493,7 @@ static VALUE libvirt_domain_send_process_signal(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.list_all_snapshots(flags=0) -> Array
*
- * Call virDomainListAllSnapshots[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainListAllSnapshots]
+ * Call virDomainListAllSnapshots[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainListAllSnapshots]
* to get an array of snapshot objects for all snapshots.
*/
static VALUE libvirt_domain_list_all_snapshots(int argc, VALUE *argv, VALUE d)
@@ -2507,7 +2511,7 @@ static VALUE libvirt_domain_list_all_snapshots(int argc, VALUE *argv, VALUE d)
* call-seq:
* snapshot.num_children(flags=0) -> Fixnum
*
- * Call virDomainSnapshotNumChildren[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotNumChildren]
+ * Call virDomainSnapshotNumChildren[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotNumChildren]
* to get the number of children snapshots of this snapshot.
*/
static VALUE libvirt_domain_snapshot_num_children(int argc, VALUE *argv,
@@ -2529,7 +2533,7 @@ static VALUE libvirt_domain_snapshot_num_children(int argc, VALUE *argv,
* call-seq:
* snapshot.list_children_names(flags=0) -> Array
*
- * Call virDomainSnapshotListChildrenNames[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotListChildrenNames]
+ * Call virDomainSnapshotListChildrenNames[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotListChildrenNames]
* to get an array of strings representing the children of this snapshot.
*/
static VALUE libvirt_domain_snapshot_list_children_names(int argc, VALUE *argv,
@@ -2593,7 +2597,7 @@ error:
* call-seq:
* snapshot.list_all_children(flags=0) -> Array
*
- * Call virDomainSnapshotListAllChildren[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotListAllChildren]
+ * Call virDomainSnapshotListAllChildren[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotListAllChildren]
* to get an array of snapshot objects that are children of this snapshot.
*/
static VALUE libvirt_domain_snapshot_list_all_children(int argc, VALUE *argv,
@@ -2612,7 +2616,7 @@ static VALUE libvirt_domain_snapshot_list_all_children(int argc, VALUE *argv,
* call-seq:
* snapshot.parent(flags=0) -> [Libvirt::Domain::Snapshot|nil]
*
- * Call virDomainSnapshotGetParent[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotGetParent]
+ * Call virDomainSnapshotGetParent[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotGetParent]
* to get the parent of this snapshot (nil will be returned if this is a root
* snapshot).
*/
@@ -2649,7 +2653,7 @@ static VALUE libvirt_domain_snapshot_parent(int argc, VALUE *argv, VALUE s)
* call-seq:
* snapshot.current?(flags=0) -> [true|false]
*
- * Call virDomainSnapshotIsCurrent[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotIsCurrent]
+ * Call virDomainSnapshotIsCurrent[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotIsCurrent]
* to determine if the snapshot is the domain's current snapshot.
*/
static VALUE libvirt_domain_snapshot_current_p(int argc, VALUE *argv, VALUE s)
@@ -2670,7 +2674,7 @@ static VALUE libvirt_domain_snapshot_current_p(int argc, VALUE *argv, VALUE s)
* call-seq:
* snapshot.has_metadata?(flags=0) -> [true|false]
*
- * Call virDomainSnapshotHasMetadata[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSnapshotHasMetadata]
+ * Call virDomainSnapshotHasMetadata[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSnapshotHasMetadata]
* to determine if the snapshot is associated with libvirt metadata.
*/
static VALUE libvirt_domain_snapshot_has_metadata_p(int argc, VALUE *argv,
@@ -2692,7 +2696,7 @@ static VALUE libvirt_domain_snapshot_has_metadata_p(int argc, VALUE *argv,
* call-seq:
* dom.memory_stats_period = Fixnum,flags=0
*
- * Call virDomainSetMemoryStatsPeriod[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetMemoryStatsPeriod]
+ * Call virDomainSetMemoryStatsPeriod[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetMemoryStatsPeriod]
* to set the memory statistics collection period.
*/
static VALUE libvirt_domain_memory_stats_period(VALUE d, VALUE in)
@@ -2714,7 +2718,7 @@ static VALUE libvirt_domain_memory_stats_period(VALUE d, VALUE in)
* call-seq:
* dom.fstrim(mountpoint=nil, minimum=0, flags=0) -> nil
*
- * Call virDomainFSTrim[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainFSTrim]
+ * Call virDomainFSTrim[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainFSTrim]
* to call FITRIM within the guest.
*/
static VALUE libvirt_domain_fstrim(int argc, VALUE *argv, VALUE d)
@@ -2736,7 +2740,7 @@ static VALUE libvirt_domain_fstrim(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.block_rebase(disk, base=nil, bandwidth=0, flags=0) -> nil
*
- * Call virDomainBlockRebase[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockRebase]
+ * Call virDomainBlockRebase[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockRebase]
* to populate a disk image with data from its backing image chain.
*/
static VALUE libvirt_domain_block_rebase(int argc, VALUE *argv, VALUE d)
@@ -2760,7 +2764,7 @@ static VALUE libvirt_domain_block_rebase(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.open_channel(name, stream, flags=0) -> nil
*
- * Call virDomainOpenChannel[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainOpenChannel]
+ * Call virDomainOpenChannel[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainOpenChannel]
* to open a channel on a guest. Note that name may be nil, in which case the
* first channel on the guest is opened.
*/
@@ -2784,7 +2788,7 @@ static VALUE libvirt_domain_open_channel(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.create_with_files(fds=nil, flags=0) -> nil
*
- * Call virDomainCreateWithFiles[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCreateWithFiles]
+ * Call virDomainCreateWithFiles[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCreateWithFiles]
* to launch a defined domain with a set of open file descriptors.
*/
static VALUE libvirt_domain_create_with_files(int argc, VALUE *argv, VALUE d)
@@ -2823,7 +2827,7 @@ static VALUE libvirt_domain_create_with_files(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.open_graphics(fd, idx=0, flags=0) -> nil
*
- * Call virDomainOpenGraphics[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainOpenGraphics]
+ * Call virDomainOpenGraphics[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainOpenGraphics]
* to connect a file descriptor to the graphics backend of the domain.
*/
static VALUE libvirt_domain_open_graphics(int argc, VALUE *argv, VALUE d)
@@ -2845,7 +2849,7 @@ static VALUE libvirt_domain_open_graphics(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.pmwakeup(flags=0) -> nil
*
- * Call virDomainPMWakeup[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainPMWakeup]
+ * Call virDomainPMWakeup[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainPMWakeup]
* to inject a wakeup into the guest.
*/
static VALUE libvirt_domain_pmwakeup(int argc, VALUE *argv, VALUE d)
@@ -2866,7 +2870,7 @@ static VALUE libvirt_domain_pmwakeup(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.block_resize(disk, size, flags=0) -> nil
*
- * Call virDomainBlockResize[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockResize]
+ * Call virDomainBlockResize[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockResize]
* to resize a block device of domain.
*/
static VALUE libvirt_domain_block_resize(int argc, VALUE *argv, VALUE d)
@@ -2888,7 +2892,7 @@ static VALUE libvirt_domain_block_resize(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.pmsuspend_for_duration(target, duration, flags=0) -> nil
*
- * Call virDomainPMSuspendForDuration[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainPMSuspendForDuration]
+ * Call virDomainPMSuspendForDuration[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainPMSuspendForDuration]
* to have the domain enter the target power management suspend level.
*/
static VALUE libvirt_domain_pmsuspend_for_duration(int argc, VALUE *argv,
@@ -2911,7 +2915,7 @@ static VALUE libvirt_domain_pmsuspend_for_duration(int argc, VALUE *argv,
* call-seq:
* dom.migrate_compression_cache(flags=0) -> Fixnum
*
- * Call virDomainMigrateGetCompressionCache[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateGetCompressionCache]
+ * Call virDomainMigrateGetCompressionCache[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateGetCompressionCache]
* to get the current size of the migration cache.
*/
static VALUE libvirt_domain_migrate_compression_cache(int argc, VALUE *argv,
@@ -2939,7 +2943,7 @@ static VALUE libvirt_domain_migrate_compression_cache(int argc, VALUE *argv,
* call-seq:
* dom.migrate_compression_cache = Fixnum,flags=0
*
- * Call virDomainMigrateSetCompressionCache[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateSetCompressionCache]
+ * Call virDomainMigrateSetCompressionCache[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateSetCompressionCache]
* to set the current size of the migration cache.
*/
static VALUE libvirt_domain_migrate_compression_cache_equal(VALUE d, VALUE in)
@@ -2961,7 +2965,7 @@ static VALUE libvirt_domain_migrate_compression_cache_equal(VALUE d, VALUE in)
* call-seq:
* dom.disk_errors(flags=0) -> Hash
*
- * Call virDomainGetDiskErrors[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetDiskErrors]
+ * Call virDomainGetDiskErrors[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetDiskErrors]
* to get errors on disks in the domain.
*/
static VALUE libvirt_domain_disk_errors(int argc, VALUE *argv, VALUE d)
@@ -3002,7 +3006,7 @@ static VALUE libvirt_domain_disk_errors(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.emulator_pin_info(flags=0) -> Array
*
- * Call virDomainGetEmulatorPinInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetEmulatorPinInfo]
+ * Call virDomainGetEmulatorPinInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetEmulatorPinInfo]
* to an array representing the mapping of emulator threads to physical CPUs.
* For each physical CPU in the machine, the array offset corresponding to that
* CPU is 'true' if an emulator thread is running on that CPU, and 'false'
@@ -3046,7 +3050,7 @@ static VALUE libvirt_domain_emulator_pin_info(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.pin_emulator(cpulist, flags=0) -> nil
*
- * Call virDomainPinVcpu[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainPinVcpu]
+ * Call virDomainPinVcpu[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainPinVcpu]
* to pin the emulator to a range of physical processors. The cpulist should
* be an array of Fixnums representing the physical processors this domain's
* emulator should be allowed to be scheduled on.
@@ -3086,7 +3090,7 @@ static VALUE libvirt_domain_pin_emulator(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.security_label_list -> [ Libvirt::Domain::SecurityLabel ]
*
- * Call virDomainGetSecurityLabelList[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetSecurityLabelList]
+ * Call virDomainGetSecurityLabelList[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetSecurityLabelList]
* to retrieve the security labels applied to this domain.
*/
static VALUE libvirt_domain_security_label_list(VALUE d)
@@ -3137,7 +3141,7 @@ static VALUE params_to_hash(VALUE in)
* call-seq:
* dom.job_stats -> Hash
*
- * Call virDomainGetJobStats[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetJobStats]
+ * Call virDomainGetJobStats[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetJobStats]
* to retrieve information about progress of a background job on a domain.
*/
static VALUE libvirt_domain_job_stats(int argc, VALUE *argv, VALUE d)
@@ -3233,7 +3237,7 @@ static const char *iotune_set(VALUE d, unsigned int flags,
* call-seq:
* dom.block_iotune(disk=nil, flags=0) -> Hash
*
- * Call virDomainGetBlockIoTune[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetBlockIoTune]
+ * Call virDomainGetBlockIoTune[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetBlockIoTune]
* to retrieve all of the block IO tune parameters for this domain. The keys
* and values in the hash that is returned are hypervisor specific.
*/
@@ -3267,7 +3271,7 @@ static struct ruby_libvirt_typed_param iotune_allowed[] = {
* call-seq:
* dom.block_iotune = disk,Hash,flags=0
*
- * Call virDomainSetBlockIoTune[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetBlockIoTune]
+ * Call virDomainSetBlockIoTune[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetBlockIoTune]
* to set the block IO tune parameters for the supplied disk on this domain.
* The keys and values in the input hash are hypervisor specific.
*/
@@ -3304,7 +3308,7 @@ static VALUE libvirt_domain_block_iotune_equal(VALUE d, VALUE in)
* call-seq:
* dom.block_commit(disk, base=nil, top=nil, bandwidth=0, flags=0) -> nil
*
- * Call virDomainBlockCommit[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockCommit]
+ * Call virDomainBlockCommit[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockCommit]
* to commit changes from a top-level backing file into a lower level base file.
*/
static VALUE libvirt_domain_block_commit(int argc, VALUE *argv, VALUE d)
@@ -3329,7 +3333,7 @@ static VALUE libvirt_domain_block_commit(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.block_pull(disk, bandwidth=0, flags=0) -> nil
*
- * Call virDomainBlockPull[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockPull]
+ * Call virDomainBlockPull[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockPull]
* to pull changes from a backing file into a disk image.
*/
static VALUE libvirt_domain_block_pull(int argc, VALUE *argv, VALUE d)
@@ -3352,7 +3356,7 @@ static VALUE libvirt_domain_block_pull(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.block_job_speed = disk,bandwidth=0,flags=0
*
- * Call virDomainBlockJobSetSpeed[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockJobSetSpeed]
+ * Call virDomainBlockJobSetSpeed[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockJobSetSpeed]
* to set the maximum allowable bandwidth a block job may consume.
*/
static VALUE libvirt_domain_block_job_speed_equal(VALUE d, VALUE in)
@@ -3398,7 +3402,7 @@ static VALUE libvirt_domain_block_job_speed_equal(VALUE d, VALUE in)
* call-seq:
* dom.block_job_info(disk, flags=0) -> Libvirt::Domain::BlockJobInfo
*
- * Call virDomainGetBlockJobInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetBlockJobInfo]
+ * Call virDomainGetBlockJobInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetBlockJobInfo]
* to get block job information for a given disk.
*/
static VALUE libvirt_domain_block_job_info(int argc, VALUE *argv, VALUE d)
@@ -3433,7 +3437,7 @@ static VALUE libvirt_domain_block_job_info(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.block_job_abort(disk, flags=0) -> nil
*
- * Call virDomainBlockJobAbort[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainBlockJobAbort]
+ * Call virDomainBlockJobAbort[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainBlockJobAbort]
* to cancel an active block job on the given disk.
*/
static VALUE libvirt_domain_block_job_abort(int argc, VALUE *argv, VALUE d)
@@ -3498,7 +3502,7 @@ static const char *interface_set(VALUE d, unsigned int flags,
* call-seq:
* dom.interface_parameters(interface, flags=0) -> Hash
*
- * Call virDomainGetInterfaceParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetInterfaceParameters]
+ * Call virDomainGetInterfaceParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetInterfaceParameters]
* to retrieve the interface parameters for the given interface on this domain.
* The keys and values in the hash that is returned are hypervisor specific.
*/
@@ -3529,7 +3533,7 @@ static struct ruby_libvirt_typed_param interface_allowed[] = {
* call-seq:
* dom.interface_parameters = device,Hash,flags=0
*
- * Call virDomainSetInterfaceParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetInterfaceParameters]
+ * Call virDomainSetInterfaceParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetInterfaceParameters]
* to set the interface parameters for the supplied device on this domain.
* The keys and values in the input hash are hypervisor specific.
*/
@@ -3595,7 +3599,7 @@ static const char *block_stats_get(VALUE d, unsigned int flags,
* call-seq:
* dom.block_stats_flags(disk, flags=0) -> Hash
*
- * Call virDomainGetBlockStatsFlags[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetBlockStatsFlags]
+ * Call virDomainGetBlockStatsFlags[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetBlockStatsFlags]
* to retrieve the block statistics for the given disk on this domain.
* The keys and values in the hash that is returned are hypervisor specific.
*/
@@ -3656,7 +3660,7 @@ static const char *numa_set(VALUE d, unsigned int flags,
* call-seq:
* dom.numa_parameters(flags=0) -> Hash
*
- * Call virDomainGetNumaParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetNumaParameters]
+ * Call virDomainGetNumaParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetNumaParameters]
* to retrieve the numa parameters for this domain. The keys and values in
* the hash that is returned are hypervisor specific.
*/
@@ -3680,7 +3684,7 @@ static struct ruby_libvirt_typed_param numa_allowed[] = {
* call-seq:
* dom.numa_parameters = Hash,flags=0
*
- * Call virDomainSetNumaParameters[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetNumaParameters]
+ * Call virDomainSetNumaParameters[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetNumaParameters]
* to set the numa parameters for this domain. The keys and values in the input
* hash are hypervisor specific.
*/
@@ -3703,7 +3707,7 @@ static VALUE libvirt_domain_numa_parameters_equal(VALUE d, VALUE in)
* call-seq:
* dom.lxc_open_namespace(flags=0) -> Array
*
- * Call virDomainLxcOpenNamespace[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainLxcOpenNamespace]
+ * Call virDomainLxcOpenNamespace[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainLxcOpenNamespace]
* to open an LXC namespace. Note that this will only work on connections to
* the LXC driver. The call will return an array of open file descriptors;
* these should be closed when use of them is finished.
@@ -3760,7 +3764,7 @@ error:
* call-seq:
* dom.qemu_agent_command(command, timeout=0, flags=0) -> String
*
- * Call virDomainQemuAgentCommand[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainQemuAgentCommand]
+ * Call virDomainQemuAgentCommand[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainQemuAgentCommand]
* to run an arbitrary command on the Qemu Agent.
*/
static VALUE libvirt_domain_qemu_agent_command(int argc, VALUE *argv, VALUE d)
@@ -3794,7 +3798,7 @@ static VALUE libvirt_domain_qemu_agent_command(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.lxc_enter_namespace(fds, flags=0) -> Array
*
- * Call virDomainLxcEnterNamespace[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainLxcEnterNamespace]
+ * Call virDomainLxcEnterNamespace[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainLxcEnterNamespace]
* to attach the process to the namespaces associated with the file descriptors
* in the fds array. Note that this call does not actually enter the namespace;
* the next call to fork will do that. Also note that this function will return
@@ -3871,7 +3875,7 @@ static struct ruby_libvirt_typed_param migrate3_allowed[] = {
* call-seq:
* dom.migrate3(dconn, Hash=nil, flags=0) -> Libvirt::Domain
*
- * Call virDomainMigrate3[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrate2]
+ * Call virDomainMigrate3[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrate2]
* to migrate a domain from the host on this connection to the connection
* referenced in dconn.
*/
@@ -3915,7 +3919,7 @@ static VALUE libvirt_domain_migrate3(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.migrate_to_uri3(duri=nil, Hash=nil, flags=0) -> nil
*
- * Call virDomainMigrateToURI3[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainMigrateToURI3]
+ * Call virDomainMigrateToURI3[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainMigrateToURI3]
* to migrate a domain from the host on this connection to the host whose
* libvirt URI is duri.
*/
@@ -3958,7 +3962,7 @@ static VALUE libvirt_domain_migrate_to_uri3(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.cpu_stats(start_cpu=-1, numcpus=1, flags=0) -> Hash
*
- * Call virDomainGetCPUStats[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetCPUStats]
+ * Call virDomainGetCPUStats[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetCPUStats]
* to get statistics about CPU usage attributable to a single domain. If
* start_cpu is -1, then numcpus must be 1 and statistics attributable to the
* entire domain is returned. If start_cpu is any positive number, then it
@@ -4050,7 +4054,7 @@ static VALUE libvirt_domain_cpu_stats(int argc, VALUE *argv, VALUE d)
/*
* call-seq:
* dom.time(flags=0) -> Hash
- * Call virDomainGetTime[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetTime]
+ * Call virDomainGetTime[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetTime]
* to get information about the guest time.
*/
static VALUE libvirt_domain_get_time(int argc, VALUE *argv, VALUE d)
@@ -4079,7 +4083,7 @@ static VALUE libvirt_domain_get_time(int argc, VALUE *argv, VALUE d)
/*
* call-seq:
* dom.time = Hash,flags=0
- * Call virDomainSetTime[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainSetTime]
+ * Call virDomainSetTime[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetTime]
* to set guest time.
*/
static VALUE libvirt_domain_time_equal(VALUE d, VALUE in)
@@ -4104,7 +4108,7 @@ static VALUE libvirt_domain_time_equal(VALUE d, VALUE in)
* call-seq:
* dom.core_dump_with_format(filename, dumpformat, flags=0) -> nil
*
- * Call virDomainCoreDumpWithFormat[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainCoreDump]
+ * Call virDomainCoreDumpWithFormat[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainCoreDump]
* to do a full memory dump of the domain to filename.
*/
static VALUE libvirt_domain_core_dump_with_format(int argc, VALUE *argv, VALUE d)
@@ -4127,7 +4131,7 @@ static VALUE libvirt_domain_core_dump_with_format(int argc, VALUE *argv, VALUE d
* call-seq:
* dom.fs_freeze(mountpoints=nil, flags=0) -> Fixnum
*
- * Call virDomainFSFreeze[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainFSFreeze]
+ * Call virDomainFSFreeze[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainFSFreeze]
* to freeze the specified filesystems within the guest.
*/
static VALUE libvirt_domain_fs_freeze(int argc, VALUE *argv, VALUE d)
@@ -4168,7 +4172,7 @@ static VALUE libvirt_domain_fs_freeze(int argc, VALUE *argv, VALUE d)
* call-seq:
* dom.fs_thaw(mountpoints=nil, flags=0) -> Fixnum
*
- * Call virDomainFSThaw[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainFSThaw]
+ * Call virDomainFSThaw[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainFSThaw]
* to thaw the specified filesystems within the guest.
*/
static VALUE libvirt_domain_fs_thaw(int argc, VALUE *argv, VALUE d)
@@ -4243,7 +4247,7 @@ static VALUE fs_info_wrap(VALUE arg)
* call-seq:
* dom.fs_info(flags=0) -> [Hash]
*
- * Call virDomainGetFSInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virDomainGetFSInfo]
+ * Call virDomainGetFSInfo[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainGetFSInfo]
* to get information about the guest filesystems.
*/
static VALUE libvirt_domain_fs_info(int argc, VALUE *argv, VALUE d)
@@ -4277,6 +4281,66 @@ static VALUE libvirt_domain_fs_info(int argc, VALUE *argv, VALUE d)
}
#endif
+#if HAVE_VIRDOMAINRENAME
+/*
+ * call-seq:
+ * dom.rename(name, flags=0) -> nil
+ *
+ * Call virDomainRename[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainRename]
+ * to rename a domain.
+ */
+static VALUE libvirt_domain_rename(int argc, VALUE *argv, VALUE d)
+{
+ VALUE flags, name;
+
+ rb_scan_args(argc, argv, "11", &name, &flags);
+
+ ruby_libvirt_generate_call_nil(virDomainRename,
+ ruby_libvirt_connect_get(d),
+ ruby_libvirt_domain_get(d),
+ StringValueCStr(name),
+ ruby_libvirt_value_to_uint(flags));
+}
+#endif
+
+#if HAVE_VIRDOMAINSETUSERPASSWORD
+/*
+ * call-seq:
+ * dom.user_password = user,password,flags=0 -> nil
+ *
+ * Call virDomainSetUserPassword[http://www.libvirt.org/html/libvirt-libvirt-domain.html#virDomainSetUserPassword]
+ * to set the user password on a domain.
+ */
+static VALUE libvirt_domain_user_password_equal(VALUE d, VALUE in)
+{
+ VALUE user, password, flags;
+
+ Check_Type(in, T_ARRAY);
+
+ if (RARRAY_LEN(in) == 2) {
+ user = rb_ary_entry(in, 0);
+ password = rb_ary_entry(in, 1);
+ flags = INT2NUM(0);
+ }
+ else if (RARRAY_LEN(in) == 3) {
+ user = rb_ary_entry(in, 0);
+ password = rb_ary_entry(in, 1);
+ flags = rb_ary_entry(in, 2);
+ }
+ else {
+ rb_raise(rb_eArgError, "wrong number of arguments (%ld for 2 or 3)",
+ RARRAY_LEN(in));
+ }
+
+ ruby_libvirt_generate_call_nil(virDomainSetUserPassword,
+ ruby_libvirt_connect_get(d),
+ ruby_libvirt_domain_get(d),
+ StringValueCStr(user),
+ StringValueCStr(password),
+ ruby_libvirt_value_to_uint(flags));
+}
+#endif
+
/*
* Class Libvirt::Domain
*/
@@ -5703,6 +5767,10 @@ void ruby_libvirt_domain_init(void)
rb_define_const(c_domain, "QEMU_AGENT_COMMAND_NOWAIT",
INT2NUM(VIR_DOMAIN_QEMU_AGENT_COMMAND_NOWAIT));
#endif
+#if HAVE_CONST_VIR_DOMAIN_QEMU_AGENT_COMMAND_SHUTDOWN
+ rb_define_const(c_domain, "QEMU_AGENT_COMMAND_SHUTDOWN",
+ INT2NUM(VIR_DOMAIN_QEMU_AGENT_COMMAND_SHUTDOWN));
+#endif
#if HAVE_CONST_VIR_DOMAIN_QEMU_MONITOR_COMMAND_DEFAULT
rb_define_const(c_domain, "QEMU_MONITOR_COMMAND_DEFAULT",
INT2NUM(VIR_DOMAIN_QEMU_MONITOR_COMMAND_DEFAULT));
@@ -5822,4 +5890,17 @@ void ruby_libvirt_domain_init(void)
#if HAVE_VIRDOMAINGETFSINFO
rb_define_method(c_domain, "fs_info", libvirt_domain_fs_info, -1);
#endif
+#if HAVE_VIRDOMAINRENAME
+ rb_define_method(c_domain, "rename", libvirt_domain_rename, -1);
+#endif
+#if HAVE_VIRDOMAINSETUSERPASSWORD
+ rb_define_method(c_domain, "user_password=", libvirt_domain_user_password_equal, 1);
+#endif
+#if HAVE_CONST_VIR_DOMAIN_PASSWORD_ENCRYPTED
+ rb_define_const(c_domain, "PASSWORD_ENCRYPTED",
+ INT2NUM(VIR_DOMAIN_PASSWORD_ENCRYPTED));
+#endif
+#if HAVE_CONST_VIR_DOMAIN_TIME_SYNC
+ rb_define_const(c_domain, "TIME_SYNC", INT2NUM(VIR_DOMAIN_TIME_SYNC));
+#endif
}
diff --git a/ext/libvirt/extconf.h b/ext/libvirt/extconf.h
index 38c0c5d..0120a7a 100644
--- a/ext/libvirt/extconf.h
+++ b/ext/libvirt/extconf.h
@@ -145,6 +145,9 @@
#define HAVE_VIRDOMAINFSTHAW 1
#define HAVE_VIRDOMAINGETFSINFO 1
#define HAVE_VIRNODEGETFREEPAGES 1
+#define HAVE_VIRDOMAINDEFINEXMLFLAGS 1
+#define HAVE_VIRDOMAINRENAME 1
+#define HAVE_VIRDOMAINSETUSERPASSWORD 1
#define HAVE_CONST_VIR_MIGRATE_LIVE 1
#define HAVE_CONST_VIR_MIGRATE_PEER2PEER 1
#define HAVE_CONST_VIR_MIGRATE_TUNNELLED 1
@@ -333,6 +336,15 @@
#define HAVE_CONST_VIR_DOMAIN_BLOCK_COMMIT_ACTIVE 1
#define HAVE_CONST_VIR_DOMAIN_BLOCK_COMMIT_RELATIVE 1
#define HAVE_CONST_VIR_DOMAIN_BLOCK_COMMIT_BANDWIDTH_BYTES 1
+#define HAVE_CONST_VIR_STORAGE_POOL_CREATE_NORMAL 1
+#define HAVE_CONST_VIR_STORAGE_POOL_CREATE_WITH_BUILD 1
+#define HAVE_CONST_VIR_STORAGE_POOL_CREATE_WITH_BUILD_OVERWRITE 1
+#define HAVE_CONST_VIR_STORAGE_POOL_CREATE_WITH_BUILD_NO_OVERWRITE 1
+#define HAVE_CONST_VIR_STORAGE_VOL_CREATE_REFLINK 1
+#define HAVE_CONST_VIR_STORAGE_VOL_DELETE_WITH_SNAPSHOTS 1
+#define HAVE_CONST_VIR_DOMAIN_DEFINE_VALIDATE 1
+#define HAVE_CONST_VIR_DOMAIN_PASSWORD_ENCRYPTED 1
+#define HAVE_CONST_VIR_DOMAIN_TIME_SYNC 1
#define HAVE_CONST_VIR_FROM_VMWARE 1
#define HAVE_CONST_VIR_FROM_AUDIT 1
#define HAVE_CONST_VIR_FROM_SYSINFO 1
diff --git a/ext/libvirt/extconf.rb b/ext/libvirt/extconf.rb
index d5f4d74..debbfac 100644
--- a/ext/libvirt/extconf.rb
+++ b/ext/libvirt/extconf.rb
@@ -222,6 +222,9 @@ libvirt_funcs = [ 'virStorageVolWipe',
'virDomainFSThaw',
'virDomainGetFSInfo',
'virNodeGetFreePages',
+ 'virDomainDefineXMLFlags',
+ 'virDomainRename',
+ 'virDomainSetUserPassword',
]
libvirt_qemu_funcs = [ 'virDomainQemuMonitorCommand',
@@ -428,6 +431,16 @@ libvirt_consts = [ 'VIR_MIGRATE_LIVE',
'VIR_DOMAIN_BLOCK_COMMIT_RELATIVE',
'VIR_DOMAIN_BLOCK_COMMIT_BANDWIDTH_BYTES',
'VIR_DOMAIN_BLOCK_IOTUNE_SIZE_IOPS_SEC',
+ 'VIR_STORAGE_POOL_CREATE_NORMAL',
+ 'VIR_STORAGE_POOL_CREATE_WITH_BUILD',
+ 'VIR_STORAGE_POOL_CREATE_WITH_BUILD_OVERWRITE',
+ 'VIR_STORAGE_POOL_CREATE_WITH_BUILD_NO_OVERWRITE',
+ 'VIR_STORAGE_VOL_CREATE_REFLINK',
+ 'VIR_STORAGE_VOL_DELETE_WITH_SNAPSHOTS',
+ 'VIR_DOMAIN_QEMU_AGENT_COMMAND_SHUTDOWN',
+ 'VIR_DOMAIN_DEFINE_VALIDATE',
+ 'VIR_DOMAIN_PASSWORD_ENCRYPTED',
+ 'VIR_DOMAIN_TIME_SYNC',
]
virterror_consts = [
diff --git a/ext/libvirt/interface.c b/ext/libvirt/interface.c
index d46da9c..f1987fd 100644
--- a/ext/libvirt/interface.c
+++ b/ext/libvirt/interface.c
@@ -2,7 +2,7 @@
* interface.c: virInterface methods
*
* Copyright (C) 2010 Red Hat Inc.
- * Copyright (C) 2013 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -48,7 +48,7 @@ VALUE ruby_libvirt_interface_new(virInterfacePtr i, VALUE conn)
* call-seq:
* interface.undefine -> nil
*
- * Call virInterfaceUndefine[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceUndefine]
+ * Call virInterfaceUndefine[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceUndefine]
* to undefine this interface.
*/
static VALUE libvirt_interface_undefine(VALUE i)
@@ -62,7 +62,7 @@ static VALUE libvirt_interface_undefine(VALUE i)
* call-seq:
* interface.create(flags=0) -> nil
*
- * Call virInterfaceCreate[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceCreate]
+ * Call virInterfaceCreate[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceCreate]
* to start this interface.
*/
static VALUE libvirt_interface_create(int argc, VALUE *argv, VALUE i)
@@ -81,7 +81,7 @@ static VALUE libvirt_interface_create(int argc, VALUE *argv, VALUE i)
* call-seq:
* interface.destroy(flags=0) -> nil
*
- * Call virInterfaceDestroy[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceDestroy]
+ * Call virInterfaceDestroy[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceDestroy]
* to shutdown this interface.
*/
static VALUE libvirt_interface_destroy(int argc, VALUE *argv, VALUE i)
@@ -101,7 +101,7 @@ static VALUE libvirt_interface_destroy(int argc, VALUE *argv, VALUE i)
* call-seq:
* interface.active? -> [true|false]
*
- * Call virInterfaceIsActive[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceIsActive]
+ * Call virInterfaceIsActive[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceIsActive]
* to determine if this interface is currently active.
*/
static VALUE libvirt_interface_active_p(VALUE p)
@@ -116,7 +116,7 @@ static VALUE libvirt_interface_active_p(VALUE p)
* call-seq:
* interface.name -> String
*
- * Call virInterfaceGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceGetName]
+ * Call virInterfaceGetName[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceGetName]
* to retrieve the name of this interface.
*/
static VALUE libvirt_interface_name(VALUE i)
@@ -130,7 +130,7 @@ static VALUE libvirt_interface_name(VALUE i)
* call-seq:
* interface.mac -> String
*
- * Call virInterfaceGetMACString[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceGetMACString]
+ * Call virInterfaceGetMACString[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceGetMACString]
* to retrieve the MAC address of this interface.
*/
static VALUE libvirt_interface_mac(VALUE i)
@@ -144,7 +144,7 @@ static VALUE libvirt_interface_mac(VALUE i)
* call-seq:
* interface.xml_desc -> String
*
- * Call virInterfaceGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceGetXMLDesc]
+ * Call virInterfaceGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceGetXMLDesc]
* to retrieve the XML of this interface.
*/
static VALUE libvirt_interface_xml_desc(int argc, VALUE *argv, VALUE i)
@@ -163,7 +163,7 @@ static VALUE libvirt_interface_xml_desc(int argc, VALUE *argv, VALUE i)
* call-seq:
* interface.free -> nil
*
- * Call virInterfaceFree[http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceFree]
+ * Call virInterfaceFree[http://www.libvirt.org/html/libvirt-libvirt-interface.html#virInterfaceFree]
* to free this interface. The object will no longer be valid after this call.
*/
static VALUE libvirt_interface_free(VALUE i)
diff --git a/ext/libvirt/network.c b/ext/libvirt/network.c
index 7c77d73..d7bbc4d 100644
--- a/ext/libvirt/network.c
+++ b/ext/libvirt/network.c
@@ -2,7 +2,7 @@
* network.c: virNetwork methods
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013,2014 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -48,7 +48,7 @@ VALUE ruby_libvirt_network_new(virNetworkPtr n, VALUE conn)
* call-seq:
* net.undefine -> nil
*
- * Call virNetworkUndefine[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkUndefine]
+ * Call virNetworkUndefine[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkUndefine]
* to undefine this network.
*/
static VALUE libvirt_network_undefine(VALUE n)
@@ -62,7 +62,7 @@ static VALUE libvirt_network_undefine(VALUE n)
* call-seq:
* net.create -> nil
*
- * Call virNetworkCreate[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkCreate]
+ * Call virNetworkCreate[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkCreate]
* to start this network.
*/
static VALUE libvirt_network_create(VALUE n)
@@ -77,7 +77,7 @@ static VALUE libvirt_network_create(VALUE n)
* call-seq:
* net.update -> nil
*
- * Call virNetworkUpdate[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkUpdate]
+ * Call virNetworkUpdate[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkUpdate]
* to update this network.
*/
static VALUE libvirt_network_update(VALUE n, VALUE command, VALUE section,
@@ -95,7 +95,7 @@ static VALUE libvirt_network_update(VALUE n, VALUE command, VALUE section,
* call-seq:
* net.destroy -> nil
*
- * Call virNetworkDestroy[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkDestroy]
+ * Call virNetworkDestroy[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkDestroy]
* to shutdown this network.
*/
static VALUE libvirt_network_destroy(VALUE n)
@@ -109,7 +109,7 @@ static VALUE libvirt_network_destroy(VALUE n)
* call-seq:
* net.name -> String
*
- * Call virNetworkGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkGetName]
+ * Call virNetworkGetName[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkGetName]
* to retrieve the name of this network.
*/
static VALUE libvirt_network_name(VALUE n)
@@ -123,7 +123,7 @@ static VALUE libvirt_network_name(VALUE n)
* call-seq:
* net.uuid -> String
*
- * Call virNetworkGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkGetUUIDString]
+ * Call virNetworkGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkGetUUIDString]
* to retrieve the UUID of this network.
*/
static VALUE libvirt_network_uuid(VALUE n)
@@ -136,7 +136,7 @@ static VALUE libvirt_network_uuid(VALUE n)
* call-seq:
* net.xml_desc(flags=0) -> String
*
- * Call virNetworkGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkGetXMLDesc]
+ * Call virNetworkGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkGetXMLDesc]
* to retrieve the XML for this network.
*/
static VALUE libvirt_network_xml_desc(int argc, VALUE *argv, VALUE n)
@@ -155,7 +155,7 @@ static VALUE libvirt_network_xml_desc(int argc, VALUE *argv, VALUE n)
* call-seq:
* net.bridge_name -> String
*
- * Call virNetworkGetBridgeName[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkGetBridgeName]
+ * Call virNetworkGetBridgeName[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkGetBridgeName]
* to retrieve the bridge name for this network.
*/
static VALUE libvirt_network_bridge_name(VALUE n)
@@ -169,7 +169,7 @@ static VALUE libvirt_network_bridge_name(VALUE n)
* call-seq:
* net.autostart? -> [true|false]
*
- * Call virNetworkGetAutostart[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkGetAutostart]
+ * Call virNetworkGetAutostart[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkGetAutostart]
* to determine if this network will be autostarted when libvirtd starts.
*/
static VALUE libvirt_network_autostart(VALUE n)
@@ -187,7 +187,7 @@ static VALUE libvirt_network_autostart(VALUE n)
* call-seq:
* net.autostart = [true|false]
*
- * Call virNetworkSetAutostart[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkSetAutostart]
+ * Call virNetworkSetAutostart[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkSetAutostart]
* to set this network to be autostarted when libvirtd starts.
*/
static VALUE libvirt_network_autostart_equal(VALUE n, VALUE autostart)
@@ -206,7 +206,7 @@ static VALUE libvirt_network_autostart_equal(VALUE n, VALUE autostart)
* call-seq:
* net.free -> nil
*
- * Call virNetworkFree[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkFree]
+ * Call virNetworkFree[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkFree]
* to free this network. The object will no longer be valid after this call.
*/
static VALUE libvirt_network_free(VALUE n)
@@ -219,7 +219,7 @@ static VALUE libvirt_network_free(VALUE n)
* call-seq:
* net.active? -> [true|false]
*
- * Call virNetworkIsActive[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkIsActive]
+ * Call virNetworkIsActive[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkIsActive]
* to determine if this network is currently active.
*/
static VALUE libvirt_network_active_p(VALUE n)
@@ -235,7 +235,7 @@ static VALUE libvirt_network_active_p(VALUE n)
* call-seq:
* net.persistent? -> [true|false]
*
- * Call virNetworkIsPersistent[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkIsPersistent]
+ * Call virNetworkIsPersistent[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkIsPersistent]
* to determine if this network is persistent.
*/
static VALUE libvirt_network_persistent_p(VALUE n)
@@ -269,14 +269,22 @@ static VALUE leases_wrap(VALUE arg)
rb_hash_aset(hash, rb_str_new2("expirytime"),
LL2NUM(lease->expirytime));
rb_hash_aset(hash, rb_str_new2("type"), INT2NUM(lease->type));
- rb_hash_aset(hash, rb_str_new2("mac"), rb_str_new2(lease->mac));
- rb_hash_aset(hash, rb_str_new2("iaid"), rb_str_new2(lease->iaid));
+ if (lease->mac) {
+ rb_hash_aset(hash, rb_str_new2("mac"), rb_str_new2(lease->mac));
+ }
+ if (lease->iaid) {
+ rb_hash_aset(hash, rb_str_new2("iaid"), rb_str_new2(lease->iaid));
+ }
rb_hash_aset(hash, rb_str_new2("ipaddr"), rb_str_new2(lease->ipaddr));
rb_hash_aset(hash, rb_str_new2("prefix"), UINT2NUM(lease->prefix));
- rb_hash_aset(hash, rb_str_new2("hostname"),
- rb_str_new2(lease->hostname));
- rb_hash_aset(hash, rb_str_new2("clientid"),
- rb_str_new2(lease->clientid));
+ if (lease->hostname) {
+ rb_hash_aset(hash, rb_str_new2("hostname"),
+ rb_str_new2(lease->hostname));
+ }
+ if (lease->clientid) {
+ rb_hash_aset(hash, rb_str_new2("clientid"),
+ rb_str_new2(lease->clientid));
+ }
rb_ary_store(result, i, hash);
}
@@ -288,7 +296,7 @@ static VALUE leases_wrap(VALUE arg)
* call-seq:
* net.dhcp_leases(mac=nil, flags=0) -> Hash
*
- * Call virNetworkGetDHCPLeases[http://www.libvirt.org/html/libvirt-libvirt.html#virNetworkGetDHCPLeases]
+ * Call virNetworkGetDHCPLeases[http://www.libvirt.org/html/libvirt-libvirt-network.html#virNetworkGetDHCPLeases]
* to retrieve the leases for this network.
*/
static VALUE libvirt_network_get_dhcp_leases(int argc, VALUE *argv, VALUE n)
diff --git a/ext/libvirt/nodedevice.c b/ext/libvirt/nodedevice.c
index f9c63e9..7c6024a 100644
--- a/ext/libvirt/nodedevice.c
+++ b/ext/libvirt/nodedevice.c
@@ -2,7 +2,7 @@
* nodedevice.c: virNodeDevice methods
*
* Copyright (C) 2010 Red Hat Inc.
- * Copyright (C) 2013 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -48,7 +48,7 @@ VALUE ruby_libvirt_nodedevice_new(virNodeDevicePtr n, VALUE conn)
* call-seq:
* nodedevice.name -> String
*
- * Call virNodeDeviceGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceGetName]
+ * Call virNodeDeviceGetName[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceGetName]
* to retrieve the name of the node device.
*/
static VALUE libvirt_nodedevice_name(VALUE c)
@@ -62,7 +62,7 @@ static VALUE libvirt_nodedevice_name(VALUE c)
* call-seq:
* nodedevice.parent -> String
*
- * Call virNodeDeviceGetParent[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceGetParent]
+ * Call virNodeDeviceGetParent[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceGetParent]
* to retrieve the parent of the node device.
*/
static VALUE libvirt_nodedevice_parent(VALUE c)
@@ -87,7 +87,7 @@ static VALUE libvirt_nodedevice_parent(VALUE c)
* call-seq:
* nodedevice.num_of_caps -> Fixnum
*
- * Call virNodeDeviceNumOfCaps[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceNumOfCaps]
+ * Call virNodeDeviceNumOfCaps[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceNumOfCaps]
* to retrieve the number of capabilities of the node device.
*/
static VALUE libvirt_nodedevice_num_of_caps(VALUE c)
@@ -101,7 +101,7 @@ static VALUE libvirt_nodedevice_num_of_caps(VALUE c)
* call-seq:
* nodedevice.list_caps -> list
*
- * Call virNodeDeviceListCaps[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceListCaps]
+ * Call virNodeDeviceListCaps[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceListCaps]
* to retrieve a list of capabilities of the node device.
*/
static VALUE libvirt_nodedevice_list_caps(VALUE c)
@@ -131,7 +131,7 @@ static VALUE libvirt_nodedevice_list_caps(VALUE c)
* call-seq:
* nodedevice.xml_desc(flags=0) -> String
*
- * Call virNodeDeviceGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceGetXMLDesc]
+ * Call virNodeDeviceGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceGetXMLDesc]
* to retrieve the XML for the node device.
*/
static VALUE libvirt_nodedevice_xml_desc(int argc, VALUE *argv, VALUE n)
@@ -150,7 +150,7 @@ static VALUE libvirt_nodedevice_xml_desc(int argc, VALUE *argv, VALUE n)
* call-seq:
* nodedevice.detach(driver=nil, flags=0) -> nil
*
- * Call virNodeDeviceDettach[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceDettach]
+ * Call virNodeDeviceDettach[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceDettach]
* to detach the node device from the node.
*/
static VALUE libvirt_nodedevice_detach(int argc, VALUE *argv, VALUE n)
@@ -184,7 +184,7 @@ static VALUE libvirt_nodedevice_detach(int argc, VALUE *argv, VALUE n)
* call-seq:
* nodedevice.reattach -> nil
*
- * Call virNodeDeviceReAttach[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceReAttach]
+ * Call virNodeDeviceReAttach[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceReAttach]
* to reattach the node device to the node.
*/
static VALUE libvirt_nodedevice_reattach(VALUE n)
@@ -198,7 +198,7 @@ static VALUE libvirt_nodedevice_reattach(VALUE n)
* call-seq:
* nodedevice.reset -> nil
*
- * Call virNodeDeviceReset[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceReset]
+ * Call virNodeDeviceReset[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceReset]
* to reset the node device.
*/
static VALUE libvirt_nodedevice_reset(VALUE n)
@@ -213,7 +213,7 @@ static VALUE libvirt_nodedevice_reset(VALUE n)
* call-seq:
* nodedevice.destroy -> nil
*
- * Call virNodeDeviceDestroy[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceDestroy]
+ * Call virNodeDeviceDestroy[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceDestroy]
* to shutdown the node device.
*/
static VALUE libvirt_nodedevice_destroy(VALUE n)
@@ -228,7 +228,7 @@ static VALUE libvirt_nodedevice_destroy(VALUE n)
* call-seq:
* nodedevice.free -> nil
*
- * Call virNodeDeviceFree[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceFree]
+ * Call virNodeDeviceFree[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceFree]
* to free the node device object. After this call the node device object is
* no longer valid.
*/
@@ -242,7 +242,7 @@ static VALUE libvirt_nodedevice_free(VALUE n)
* call-seq:
* nodedevice.lookup_scsi_host_by_wwn(wwnn, wwpn, flags=0) -> Libvirt::NodeDevice
*
- * Call virNodeDeviceLookupSCSIHostByWWN[http://www.libvirt.org/html/libvirt-libvirt.html#virNodeDeviceLookupSCSIHostByWWN]
+ * Call virNodeDeviceLookupSCSIHostByWWN[http://www.libvirt.org/html/libvirt-libvirt-nodedev.html#virNodeDeviceLookupSCSIHostByWWN]
* to look up a SCSI host by its WWNN and WWPN.
*/
static VALUE libvirt_nodedevice_lookup_scsi_host_by_wwn(int argc, VALUE *argv,
diff --git a/ext/libvirt/nwfilter.c b/ext/libvirt/nwfilter.c
index 494eb96..7160e2d 100644
--- a/ext/libvirt/nwfilter.c
+++ b/ext/libvirt/nwfilter.c
@@ -2,7 +2,7 @@
* nwfilter.c: virNWFilter methods
*
* Copyright (C) 2010 Red Hat Inc.
- * Copyright (C) 2013 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -48,7 +48,7 @@ VALUE ruby_libvirt_nwfilter_new(virNWFilterPtr n, VALUE conn)
* call-seq:
* nwfilter.undefine -> nil
*
- * Call virNWFilterUndefine[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterUndefine]
+ * Call virNWFilterUndefine[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterUndefine]
* to undefine the network filter.
*/
static VALUE libvirt_nwfilter_undefine(VALUE n)
@@ -62,7 +62,7 @@ static VALUE libvirt_nwfilter_undefine(VALUE n)
* call-seq:
* nwfilter.name -> String
*
- * Call virNWFilterGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterGetName]
+ * Call virNWFilterGetName[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterGetName]
* to retrieve the network filter name.
*/
static VALUE libvirt_nwfilter_name(VALUE n)
@@ -76,7 +76,7 @@ static VALUE libvirt_nwfilter_name(VALUE n)
* call-seq:
* nwfilter.uuid -> String
*
- * Call virNWFilterGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterGetUUIDString]
+ * Call virNWFilterGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterGetUUIDString]
* to retrieve the network filter UUID.
*/
static VALUE libvirt_nwfilter_uuid(VALUE n)
@@ -89,7 +89,7 @@ static VALUE libvirt_nwfilter_uuid(VALUE n)
* call-seq:
* nwfilter.xml_desc(flags=0) -> String
*
- * Call virNWFilterGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterGetXMLDesc]
+ * Call virNWFilterGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterGetXMLDesc]
* to retrieve the XML for this network filter.
*/
static VALUE libvirt_nwfilter_xml_desc(int argc, VALUE *argv, VALUE n)
@@ -108,7 +108,7 @@ static VALUE libvirt_nwfilter_xml_desc(int argc, VALUE *argv, VALUE n)
* call-seq:
* nwfilter.free -> nil
*
- * Call virNWFilterFree[http://www.libvirt.org/html/libvirt-libvirt.html#virNWFilterFree]
+ * Call virNWFilterFree[http://www.libvirt.org/html/libvirt-libvirt-nwfilter.html#virNWFilterFree]
* to free this network filter. After this call the network filter object is
* no longer valid.
*/
diff --git a/ext/libvirt/secret.c b/ext/libvirt/secret.c
index f083e0d..a642ef3 100644
--- a/ext/libvirt/secret.c
+++ b/ext/libvirt/secret.c
@@ -2,7 +2,7 @@
* secret.c: virSecret methods
*
* Copyright (C) 2010 Red Hat Inc.
- * Copyright (C) 2013 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -48,7 +48,7 @@ VALUE ruby_libvirt_secret_new(virSecretPtr s, VALUE conn)
* call-seq:
* secret.uuid -> String
*
- * Call virSecretGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretGetUUIDString]
+ * Call virSecretGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretGetUUIDString]
* to retrieve the UUID for this secret.
*/
static VALUE libvirt_secret_uuid(VALUE s)
@@ -61,7 +61,7 @@ static VALUE libvirt_secret_uuid(VALUE s)
* call-seq:
* secret.usagetype -> Fixnum
*
- * Call virSecretGetUsageType[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretGetUsageType]
+ * Call virSecretGetUsageType[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretGetUsageType]
* to retrieve the usagetype for this secret.
*/
static VALUE libvirt_secret_usagetype(VALUE s)
@@ -75,7 +75,7 @@ static VALUE libvirt_secret_usagetype(VALUE s)
* call-seq:
* secret.usageid -> String
*
- * Call virSecretGetUsageID[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretGetUsageID]
+ * Call virSecretGetUsageID[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretGetUsageID]
* to retrieve the usageid for this secret.
*/
static VALUE libvirt_secret_usageid(VALUE s)
@@ -89,7 +89,7 @@ static VALUE libvirt_secret_usageid(VALUE s)
* call-seq:
* secret.xml_desc(flags=0) -> String
*
- * Call virSecretGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretGetXMLDesc]
+ * Call virSecretGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretGetXMLDesc]
* to retrieve the XML for this secret.
*/
static VALUE libvirt_secret_xml_desc(int argc, VALUE *argv, VALUE s)
@@ -108,7 +108,7 @@ static VALUE libvirt_secret_xml_desc(int argc, VALUE *argv, VALUE s)
* call-seq:
* secret.set_value(value, flags=0) -> nil
*
- * Call virSecretSetValue[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretSetValue]
+ * Call virSecretSetValue[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretSetValue]
* to set a new value in this secret. Deprecated; use secret.value= instead.
*/
static VALUE libvirt_secret_set_value(int argc, VALUE *argv, VALUE s)
@@ -131,7 +131,7 @@ static VALUE libvirt_secret_set_value(int argc, VALUE *argv, VALUE s)
* call-seq:
* secret.value = value,flags=0
*
- * Call virSecretSetValue[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretSetValue]
+ * Call virSecretSetValue[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretSetValue]
* to set a new value in this secret.
*/
static VALUE libvirt_secret_value_equal(VALUE s, VALUE in)
@@ -168,7 +168,7 @@ static VALUE libvirt_secret_value_equal(VALUE s, VALUE in)
* call-seq:
* secret.value(flags=0) -> String
*
- * Call virSecretGetValue[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretGetValue]
+ * Call virSecretGetValue[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretGetValue]
* to retrieve the value from this secret.
*/
static VALUE libvirt_secret_value(int argc, VALUE *argv, VALUE s)
@@ -203,7 +203,7 @@ static VALUE libvirt_secret_value(int argc, VALUE *argv, VALUE s)
* call-seq:
* secret.undefine -> nil
*
- * Call virSecretUndefine[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretUndefine]
+ * Call virSecretUndefine[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretUndefine]
* to undefine this secret.
*/
static VALUE libvirt_secret_undefine(VALUE s)
@@ -217,7 +217,7 @@ static VALUE libvirt_secret_undefine(VALUE s)
* call-seq:
* secret.free -> nil
*
- * Call virSecretFree[http://www.libvirt.org/html/libvirt-libvirt.html#virSecretFree]
+ * Call virSecretFree[http://www.libvirt.org/html/libvirt-libvirt-secret.html#virSecretFree]
* to free this secret. After this call the secret object is no longer valid.
*/
static VALUE libvirt_secret_free(VALUE s)
diff --git a/ext/libvirt/storage.c b/ext/libvirt/storage.c
index eed028e..e576d4a 100644
--- a/ext/libvirt/storage.c
+++ b/ext/libvirt/storage.c
@@ -2,7 +2,7 @@
* storage.c: virStoragePool and virStorageVolume methods
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013,2014 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -64,7 +64,7 @@ VALUE pool_new(virStoragePoolPtr p, VALUE conn)
* call-seq:
* vol.pool -> Libvirt::StoragePool
*
- * Call virStoragePoolLookupByVolume[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolLookupByVolume]
+ * Call virStoragePoolLookupByVolume[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolLookupByVolume]
* to retrieve the storage pool for this volume.
*/
static VALUE libvirt_storage_vol_pool(VALUE v)
@@ -83,7 +83,7 @@ static VALUE libvirt_storage_vol_pool(VALUE v)
* call-seq:
* pool.build(flags=0) -> nil
*
- * Call virStoragePoolBuild[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolBuild]
+ * Call virStoragePoolBuild[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolBuild]
* to build this storage pool.
*/
static VALUE libvirt_storage_pool_build(int argc, VALUE *argv, VALUE p)
@@ -102,7 +102,7 @@ static VALUE libvirt_storage_pool_build(int argc, VALUE *argv, VALUE p)
* call-seq:
* pool.undefine -> nil
*
- * Call virStoragePoolUndefine[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolUndefine]
+ * Call virStoragePoolUndefine[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolUndefine]
* to undefine this storage pool.
*/
static VALUE libvirt_storage_pool_undefine(VALUE p)
@@ -116,7 +116,7 @@ static VALUE libvirt_storage_pool_undefine(VALUE p)
* call-seq:
* pool.create(flags=0) -> nil
*
- * Call virStoragePoolCreate[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolCreate]
+ * Call virStoragePoolCreate[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolCreate]
* to start this storage pool.
*/
static VALUE libvirt_storage_pool_create(int argc, VALUE *argv, VALUE p)
@@ -135,7 +135,7 @@ static VALUE libvirt_storage_pool_create(int argc, VALUE *argv, VALUE p)
* call-seq:
* pool.destroy -> nil
*
- * Call virStoragePoolDestroy[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolDestroy]
+ * Call virStoragePoolDestroy[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolDestroy]
* to shutdown this storage pool.
*/
static VALUE libvirt_storage_pool_destroy(VALUE p)
@@ -149,7 +149,7 @@ static VALUE libvirt_storage_pool_destroy(VALUE p)
* call-seq:
* pool.delete(flags=0) -> nil
*
- * Call virStoragePoolDelete[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolDelete]
+ * Call virStoragePoolDelete[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolDelete]
* to delete the data corresponding to this data pool. This is a destructive
* operation.
*/
@@ -169,7 +169,7 @@ static VALUE libvirt_storage_pool_delete(int argc, VALUE *argv, VALUE p)
* call-seq:
* pool.refresh(flags=0) -> nil
*
- * Call virStoragePoolRefresh[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolRefresh]
+ * Call virStoragePoolRefresh[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolRefresh]
* to refresh the list of volumes in this storage pool.
*/
static VALUE libvirt_storage_pool_refresh(int argc, VALUE *argv, VALUE p)
@@ -188,7 +188,7 @@ static VALUE libvirt_storage_pool_refresh(int argc, VALUE *argv, VALUE p)
* call-seq:
* pool.name -> String
*
- * Call virStoragePoolGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolGetName]
+ * Call virStoragePoolGetName[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolGetName]
* to retrieve the name of this storage pool.
*/
static VALUE libvirt_storage_pool_name(VALUE p)
@@ -202,7 +202,7 @@ static VALUE libvirt_storage_pool_name(VALUE p)
* call-seq:
* pool.uuid -> String
*
- * Call virStoragePoolGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolGetUUIDString]
+ * Call virStoragePoolGetUUIDString[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolGetUUIDString]
* to retrieve the UUID of this storage pool.
*/
static VALUE libvirt_storage_pool_uuid(VALUE p)
@@ -215,7 +215,7 @@ static VALUE libvirt_storage_pool_uuid(VALUE p)
* call-seq:
* pool.info -> Libvirt::StoragePoolInfo
*
- * Call virStoragePoolGetInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolGetInfo]
+ * Call virStoragePoolGetInfo[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolGetInfo]
* to retrieve information about this storage pool.
*/
static VALUE libvirt_storage_pool_info(VALUE p)
@@ -242,7 +242,7 @@ static VALUE libvirt_storage_pool_info(VALUE p)
* call-seq:
* pool.xml_desc(flags=0) -> String
*
- * Call virStoragePoolGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolGetXMLDesc]
+ * Call virStoragePoolGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolGetXMLDesc]
* to retrieve the XML for this storage pool.
*/
static VALUE libvirt_storage_pool_xml_desc(int argc, VALUE *argv, VALUE p)
@@ -261,7 +261,7 @@ static VALUE libvirt_storage_pool_xml_desc(int argc, VALUE *argv, VALUE p)
* call-seq:
* pool.autostart? -> [true|false]
*
- * Call virStoragePoolGetAutostart[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolGetAutostart]
+ * Call virStoragePoolGetAutostart[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolGetAutostart]
* to determine whether this storage pool will autostart when libvirtd starts.
*/
static VALUE libvirt_storage_pool_autostart(VALUE p)
@@ -280,7 +280,7 @@ static VALUE libvirt_storage_pool_autostart(VALUE p)
* call-seq:
* pool.autostart = [true|false]
*
- * Call virStoragePoolSetAutostart[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolSetAutostart]
+ * Call virStoragePoolSetAutostart[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolSetAutostart]
* to make this storage pool start when libvirtd starts.
*/
static VALUE libvirt_storage_pool_autostart_equal(VALUE p, VALUE autostart)
@@ -299,7 +299,7 @@ static VALUE libvirt_storage_pool_autostart_equal(VALUE p, VALUE autostart)
* call-seq:
* pool.num_of_volumes -> Fixnum
*
- * Call virStoragePoolNumOfVolumes[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolNumOfVolumes]
+ * Call virStoragePoolNumOfVolumes[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolNumOfVolumes]
* to retrieve the number of volumes in this storage pool.
*/
static VALUE libvirt_storage_pool_num_of_volumes(VALUE p)
@@ -318,7 +318,7 @@ static VALUE libvirt_storage_pool_num_of_volumes(VALUE p)
* call-seq:
* pool.list_volumes -> list
*
- * Call virStoragePoolListVolumes[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolListVolumes]
+ * Call virStoragePoolListVolumes[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolListVolumes]
* to retrieve a list of volume names in this storage pools.
*/
static VALUE libvirt_storage_pool_list_volumes(VALUE p)
@@ -347,7 +347,7 @@ static VALUE libvirt_storage_pool_list_volumes(VALUE p)
* call-seq:
* pool.free -> nil
*
- * Call virStoragePoolFree[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolFree]
+ * Call virStoragePoolFree[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolFree]
* to free this storage pool object. After this call the storage pool object
* is no longer valid.
*/
@@ -378,7 +378,7 @@ static VALUE vol_new(virStorageVolPtr v, VALUE conn)
* call-seq:
* pool.lookup_volume_by_name(name) -> Libvirt::StorageVol
*
- * Call virStorageVolLookupByName[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolLookupByName]
+ * Call virStorageVolLookupByName[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolLookupByName]
* to retrieve a storage volume object by name.
*/
static VALUE libvirt_storage_pool_lookup_vol_by_name(VALUE p, VALUE name)
@@ -397,7 +397,7 @@ static VALUE libvirt_storage_pool_lookup_vol_by_name(VALUE p, VALUE name)
* call-seq:
* pool.lookup_volume_by_key(key) -> Libvirt::StorageVol
*
- * Call virStorageVolLookupByKey[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolLookupByKey]
+ * Call virStorageVolLookupByKey[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolLookupByKey]
* to retrieve a storage volume object by key.
*/
static VALUE libvirt_storage_pool_lookup_vol_by_key(VALUE p, VALUE key)
@@ -418,7 +418,7 @@ static VALUE libvirt_storage_pool_lookup_vol_by_key(VALUE p, VALUE key)
* call-seq:
* pool.lookup_volume_by_path(path) -> Libvirt::StorageVol
*
- * Call virStorageVolLookupByPath[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolLookupByPath]
+ * Call virStorageVolLookupByPath[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolLookupByPath]
* to retrieve a storage volume object by path.
*/
static VALUE libvirt_storage_pool_lookup_vol_by_path(VALUE p, VALUE path)
@@ -440,7 +440,7 @@ static VALUE libvirt_storage_pool_lookup_vol_by_path(VALUE p, VALUE path)
* call-seq:
* pool.list_all_volumes(flags=0) -> Array
*
- * Call virStoragePoolListAllVolumes[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolListAllVolumes]
+ * Call virStoragePoolListAllVolumes[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolListAllVolumes]
* to get an array of volume objects for all volumes.
*/
static VALUE libvirt_storage_pool_list_all_volumes(int argc, VALUE *argv,
@@ -457,7 +457,7 @@ static VALUE libvirt_storage_pool_list_all_volumes(int argc, VALUE *argv,
* call-seq:
* vol.name -> String
*
- * Call virStorageVolGetName[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetName]
+ * Call virStorageVolGetName[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolGetName]
* to retrieve the name of this storage volume.
*/
static VALUE libvirt_storage_vol_name(VALUE v)
@@ -471,7 +471,7 @@ static VALUE libvirt_storage_vol_name(VALUE v)
* call-seq:
* vol.key -> String
*
- * Call virStorageVolGetKey[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetKey]
+ * Call virStorageVolGetKey[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolGetKey]
* to retrieve the key for this storage volume.
*/
static VALUE libvirt_storage_vol_key(VALUE v)
@@ -485,7 +485,7 @@ static VALUE libvirt_storage_vol_key(VALUE v)
* call-seq:
* pool.create_volume_xml(xml, flags=0) -> Libvirt::StorageVol
*
- * Call virStorageVolCreateXML[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolCreateXML]
+ * Call virStorageVolCreateXML[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolCreateXML]
* to create a new storage volume from xml.
*/
static VALUE libvirt_storage_pool_create_volume_xml(int argc, VALUE *argv,
@@ -509,7 +509,7 @@ static VALUE libvirt_storage_pool_create_volume_xml(int argc, VALUE *argv,
* call-seq:
* pool.create_volume_xml_from(xml, clonevol, flags=0) -> Libvirt::StorageVol
*
- * Call virStorageVolCreateXMLFrom[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolCreateXMLFrom]
+ * Call virStorageVolCreateXMLFrom[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolCreateXMLFrom]
* to clone a volume from an existing volume with the properties specified in
* xml.
*/
@@ -537,7 +537,7 @@ static VALUE libvirt_storage_pool_create_volume_xml_from(int argc, VALUE *argv,
* call-seq:
* pool.active? -> [true|false]
*
- * Call virStoragePoolIsActive[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolIsActive]
+ * Call virStoragePoolIsActive[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolIsActive]
* to determine if this storage pool is active.
*/
static VALUE libvirt_storage_pool_active_p(VALUE p)
@@ -553,7 +553,7 @@ static VALUE libvirt_storage_pool_active_p(VALUE p)
* call-seq:
* pool.persistent? -> [true|false]
*
- * Call virStoragePoolIsPersistent[http://www.libvirt.org/html/libvirt-libvirt.html#virStoragePoolIsPersistent]
+ * Call virStoragePoolIsPersistent[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStoragePoolIsPersistent]
* to determine if this storage pool is persistent.
*/
static VALUE libvirt_storage_pool_persistent_p(VALUE p)
@@ -568,7 +568,7 @@ static VALUE libvirt_storage_pool_persistent_p(VALUE p)
* call-seq:
* vol.delete(flags=0) -> nil
*
- * Call virStorageVolDelete[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolDelete]
+ * Call virStorageVolDelete[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolDelete]
* to delete this volume. This is a destructive operation.
*/
static VALUE libvirt_storage_vol_delete(int argc, VALUE *argv, VALUE v)
@@ -588,7 +588,7 @@ static VALUE libvirt_storage_vol_delete(int argc, VALUE *argv, VALUE v)
* call-seq:
* vol.wipe(flags=0) -> nil
*
- * Call virStorageVolWipe[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolWipe]
+ * Call virStorageVolWipe[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolWipe]
* to wipe the data from this storage volume. This is a destructive operation.
*/
static VALUE libvirt_storage_vol_wipe(int argc, VALUE *argv, VALUE v)
@@ -608,7 +608,7 @@ static VALUE libvirt_storage_vol_wipe(int argc, VALUE *argv, VALUE v)
* call-seq:
* vol.info -> Libvirt::StorageVolInfo
*
- * Call virStorageVolGetInfo[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetInfo]
+ * Call virStorageVolGetInfo[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolGetInfo]
* to retrieve information about this storage volume.
*/
static VALUE libvirt_storage_vol_info(VALUE v)
@@ -633,7 +633,7 @@ static VALUE libvirt_storage_vol_info(VALUE v)
* call-seq:
* vol.xml_desc(flags=0) -> String
*
- * Call virStorageVolGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetXMLDesc]
+ * Call virStorageVolGetXMLDesc[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolGetXMLDesc]
* to retrieve the xml for this storage volume.
*/
static VALUE libvirt_storage_vol_xml_desc(int argc, VALUE *argv, VALUE v)
@@ -652,7 +652,7 @@ static VALUE libvirt_storage_vol_xml_desc(int argc, VALUE *argv, VALUE v)
* call-seq:
* vol.path -> String
*
- * Call virStorageVolGetPath[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolGetPath]
+ * Call virStorageVolGetPath[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolGetPath]
* to retrieve the path for this storage volume.
*/
static VALUE libvirt_storage_vol_path(VALUE v)
@@ -666,7 +666,7 @@ static VALUE libvirt_storage_vol_path(VALUE v)
* call-seq:
* vol.free -> nil
*
- * Call virStorageVolFree[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolFree]
+ * Call virStorageVolFree[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolFree]
* to free the storage volume object. After this call the storage volume object
* is no longer valid.
*/
@@ -681,7 +681,7 @@ static VALUE libvirt_storage_vol_free(VALUE v)
* call-seq:
* vol.download(stream, offset, length, flags=0) -> nil
*
- * Call virStorageVolDownload[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolDownload]
+ * Call virStorageVolDownload[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolDownload]
* to download the content of a volume as a stream.
*/
static VALUE libvirt_storage_vol_download(int argc, VALUE *argv, VALUE v)
@@ -701,7 +701,7 @@ static VALUE libvirt_storage_vol_download(int argc, VALUE *argv, VALUE v)
* call-seq:
* vol.upload(stream, offset, length, flags=0) -> nil
*
- * Call virStorageVolUpload[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolUpload]
+ * Call virStorageVolUpload[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolUpload]
* to upload new content to a volume from a stream.
*/
static VALUE libvirt_storage_vol_upload(int argc, VALUE *argv, VALUE v)
@@ -723,7 +723,7 @@ static VALUE libvirt_storage_vol_upload(int argc, VALUE *argv, VALUE v)
* call-seq:
* vol.wipe_pattern(alg, flags=0) -> nil
*
- * Call virStorageVolWipePattern[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolWipePattern]
+ * Call virStorageVolWipePattern[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolWipePattern]
* to wipe the data from this storage volume. This is a destructive operation.
*/
static VALUE libvirt_storage_vol_wipe_pattern(int argc, VALUE *argv, VALUE v)
@@ -744,7 +744,7 @@ static VALUE libvirt_storage_vol_wipe_pattern(int argc, VALUE *argv, VALUE v)
* call-seq:
* vol.resize(capacity, flags=0) -> nil
*
- * Call virStorageVolResize[http://www.libvirt.org/html/libvirt-libvirt.html#virStorageVolResize]
+ * Call virStorageVolResize[http://www.libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolResize]
* to resize the associated storage volume.
*/
static VALUE libvirt_storage_vol_resize(int argc, VALUE *argv, VALUE v)
@@ -815,6 +815,27 @@ void ruby_libvirt_storage_init(void)
rb_define_const(c_storage_pool, "CREATE_PREALLOC_METADATA",
INT2NUM(VIR_STORAGE_VOL_CREATE_PREALLOC_METADATA));
#endif
+#if HAVE_CONST_VIR_STORAGE_VOL_CREATE_REFLINK
+ rb_define_const(c_storage_pool, "CREATE_REFLINK",
+ INT2NUM(VIR_STORAGE_VOL_CREATE_REFLINK));
+#endif
+
+#if HAVE_CONST_VIR_STORAGE_POOL_CREATE_NORMAL
+ rb_define_const(c_storage_pool, "CREATE_NORMAL",
+ INT2NUM(VIR_STORAGE_POOL_CREATE_NORMAL));
+#endif
+#if HAVE_CONST_VIR_STORAGE_POOL_CREATE_WITH_BUILD
+ rb_define_const(c_storage_pool, "CREATE_WITH_BUILD",
+ INT2NUM(VIR_STORAGE_POOL_CREATE_WITH_BUILD));
+#endif
+#if HAVE_CONST_VIR_STORAGE_POOL_CREATE_WITH_BUILD_OVERWRITE
+ rb_define_const(c_storage_pool, "CREATE_WITH_BUILD_OVERWRITE",
+ INT2NUM(VIR_STORAGE_POOL_CREATE_WITH_BUILD_OVERWRITE));
+#endif
+#if HAVE_CONST_VIR_STORAGE_POOL_CREATE_WITH_BUILD_NO_OVERWRITE
+ rb_define_const(c_storage_pool, "CREATE_WITH_BUILD_NO_OVERWRITE",
+ INT2NUM(VIR_STORAGE_POOL_CREATE_WITH_BUILD_NO_OVERWRITE));
+#endif
/* Creating/destroying pools */
rb_define_method(c_storage_pool, "build", libvirt_storage_pool_build, -1);
@@ -922,6 +943,10 @@ void ruby_libvirt_storage_init(void)
INT2NUM(VIR_STORAGE_VOL_DELETE_NORMAL));
rb_define_const(c_storage_vol, "DELETE_ZEROED",
INT2NUM(VIR_STORAGE_VOL_DELETE_ZEROED));
+#if HAVE_CONST_VIR_STORAGE_VOL_DELETE_WITH_SNAPSHOTS
+ rb_define_const(c_storage_vol, "DELETE_WITH_SNAPSHOTS",
+ INT2NUM(VIR_STORAGE_VOL_DELETE_WITH_SNAPSHOTS));
+#endif
rb_define_method(c_storage_vol, "pool", libvirt_storage_vol_pool, 0);
rb_define_method(c_storage_vol, "name", libvirt_storage_vol_name, 0);
diff --git a/ext/libvirt/stream.c b/ext/libvirt/stream.c
index 129adf9..c171535 100644
--- a/ext/libvirt/stream.c
+++ b/ext/libvirt/stream.c
@@ -2,7 +2,7 @@
* stream.c: virStream methods
*
* Copyright (C) 2007,2010 Red Hat Inc.
- * Copyright (C) 2013 Chris Lalancette <clalancette at gmail.com>
+ * Copyright (C) 2013-2016 Chris Lalancette <clalancette at gmail.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -48,7 +48,7 @@ VALUE ruby_libvirt_stream_new(virStreamPtr s, VALUE conn)
* call-seq:
* stream.send(buffer) -> Fixnum
*
- * Call virStreamSend[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamSend]
+ * Call virStreamSend[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamSend]
* to send the data in buffer out to the stream. The return value is the
* number of bytes sent, which may be less than the size of the buffer. If
* an error occurred, -1 is returned. If the transmit buffers are full and the
@@ -72,7 +72,7 @@ static VALUE libvirt_stream_send(VALUE s, VALUE buffer)
* call-seq:
* stream.recv(bytes) -> [return_value, data]
*
- * Call virStreamRecv[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamRecv]
+ * Call virStreamRecv[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamRecv]
* to receive up to bytes amount of data from the stream. The return is an
* array with two elements; the return code from the virStreamRecv call and
* the data (as a String) read from the stream. If an error occurred, the
@@ -131,14 +131,14 @@ static int internal_sendall(virStreamPtr RUBY_LIBVIRT_UNUSED(st), char *data,
memcpy(data, RSTRING_PTR(buffer), RSTRING_LEN(buffer));
- return NUM2INT(retcode);
+ return RSTRING_LEN(buffer);
}
/*
* call-seq:
* stream.sendall(opaque=nil){|opaque, nbytes| send block} -> nil
*
- * Call virStreamSendAll[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamSendAll]
+ * Call virStreamSendAll[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamSendAll]
* to send the entire data stream. The send block is required and is executed
* one or more times to send data. Each invocation of the send block yields
* the opaque data passed into the initial call and the number of bytes this
@@ -184,7 +184,7 @@ static int internal_recvall(virStreamPtr RUBY_LIBVIRT_UNUSED(st),
* call-seq:
* stream.recvall(opaque){|data, opaque| receive block} -> nil
*
- * Call virStreamRecvAll[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamRecvAll]
+ * Call virStreamRecvAll[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamRecvAll]
* to receive the entire data stream. The receive block is required and is
* called one or more times to receive data. Each invocation of the receive
* block yields the data received and the opaque data passed into the initial
@@ -246,7 +246,7 @@ static void stream_event_callback(virStreamPtr st, int events, void *opaque)
* call-seq:
* stream.event_add_callback(events, callback, opaque=nil) -> nil
*
- * Call virStreamEventAddCallback[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamEventAddCallback]
+ * Call virStreamEventAddCallback[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamEventAddCallback]
* to register a callback to be notified when a stream becomes readable or
* writeable. The events parameter is an integer representing the events the
* user is interested in; it should be one or more of EVENT_READABLE,
@@ -288,7 +288,7 @@ static VALUE libvirt_stream_event_add_callback(int argc, VALUE *argv, VALUE s)
* call-seq:
* stream.event_update_callback(events) -> nil
*
- * Call virStreamEventUpdateCallback[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamEventUpdateCallback]
+ * Call virStreamEventUpdateCallback[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamEventUpdateCallback]
* to change the events that the event callback is looking for. The events
* parameter is an integer representing the events the user is interested in;
* it should be one or more of EVENT_READABLE, EVENT_WRITABLE, EVENT_ERROR,
@@ -305,7 +305,7 @@ static VALUE libvirt_stream_event_update_callback(VALUE s, VALUE events)
* call-seq:
* stream.event_remove_callback -> nil
*
- * Call virStreamEventRemoveCallback[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamEventRemoveCallback]
+ * Call virStreamEventRemoveCallback[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamEventRemoveCallback]
* to remove the event callback currently registered to this stream.
*/
static VALUE libvirt_stream_event_remove_callback(VALUE s)
@@ -319,7 +319,7 @@ static VALUE libvirt_stream_event_remove_callback(VALUE s)
* call-seq:
* stream.finish -> nil
*
- * Call virStreamFinish[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamFinish]
+ * Call virStreamFinish[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamFinish]
* to finish this stream. Finish is typically used when the stream is no
* longer needed and needs to be cleaned up.
*/
@@ -333,7 +333,7 @@ static VALUE libvirt_stream_finish(VALUE s)
* call-seq:
* stream.abort -> nil
*
- * Call virStreamAbort[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamAbort]
+ * Call virStreamAbort[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamAbort]
* to abort this stream. Abort is typically used when something on the stream
* has failed, and the stream needs to be cleaned up.
*/
@@ -347,7 +347,7 @@ static VALUE libvirt_stream_abort(VALUE s)
* call-seq:
* stream.free -> nil
*
- * Call virStreamFree[http://www.libvirt.org/html/libvirt-libvirt.html#virStreamFree]
+ * Call virStreamFree[http://www.libvirt.org/html/libvirt-libvirt-stream.html#virStreamFree]
* to free this stream. The object will no longer be valid after this call.
*/
static VALUE libvirt_stream_free(VALUE s)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-libvirt/ruby-libvirt.git
More information about the Pkg-libvirt-commits
mailing list