494e2d1303
d8a0a788-xmlbuilder-01.patch 559e813b-xmlbuilder-02.patch a931a1a6-xmlbuilder-03.patch 835ddc5f-xmlbuilder-04.patch b08647c2-xmlbuilder-05.patch b31c0b44-Add-classes-for-defining-SMBios-information.patch a3206f89-Add-the-sysinfo-option.patch OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=329
37 lines
1.7 KiB
Diff
37 lines
1.7 KiB
Diff
References: fate#319621
|
|
|
|
Subject: xmlbuilder: Update XMLProperty docs
|
|
From: Cole Robinson crobinso@redhat.com Mon Jul 18 12:46:59 2016 -0400
|
|
Date: Mon Jul 18 14:46:50 2016 -0400:
|
|
Git: d8a0a78805b17778c37d181f7b3a0be145536e9b
|
|
|
|
|
|
Index: virt-manager-1.4.0/virtinst/xmlbuilder.py
|
|
===================================================================
|
|
--- virt-manager-1.4.0.orig/virtinst/xmlbuilder.py
|
|
+++ virt-manager-1.4.0/virtinst/xmlbuilder.py
|
|
@@ -340,15 +340,16 @@ class XMLProperty(property):
|
|
is_bool=False, is_int=False, is_yesno=False, is_onoff=False,
|
|
default_cb=None, default_name=None, do_abspath=False):
|
|
"""
|
|
- Set a XMLBuilder class property that represents a value in the
|
|
- <domain> XML. For example
|
|
+ Set a XMLBuilder class property that maps to a value in an XML
|
|
+ document, indicated by the passed xpath. For example, for a
|
|
+ <domain><name> the definition may look like:
|
|
|
|
- name = XMLProperty(get_name, set_name, xpath="/domain/name")
|
|
+ name = XMLProperty("./name")
|
|
|
|
- When building XML from scratch (virt-install), name is a regular
|
|
- class property. When parsing and editting existing guest XML, we
|
|
- use the xpath value to map the name property to the underlying XML
|
|
- definition.
|
|
+ When building XML from scratch (virt-install), 'name' works
|
|
+ similar to a regular class property(). When parsing and editing
|
|
+ existing guest XML, we use the xpath value to get/set the value
|
|
+ in the parsed XML document.
|
|
|
|
@param doc: option doc string for the property
|
|
@param xpath: xpath string which maps to the associated property
|