Blob Blame History Raw
From 96576fef61fdc36b342517ef517e1b30b74af1a1 Mon Sep 17 00:00:00 2001
Message-Id: <96576fef61fdc36b342517ef517e1b30b74af1a1@dist-git>
From: Peter Krempa <pkrempa@redhat.com>
Date: Wed, 26 Feb 2014 14:55:13 +0100
Subject: [PATCH] snapshot: schema: Split out snapshot disk driver definition

https://bugzilla.redhat.com/show_bug.cgi?id=1032370

Extract the definition to a new type to allow avoiding of duplication.

(cherry picked from commit 32487c86c6e8ab35153f5110897ebd94c65ffb8c)

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
---
 docs/schemas/domainsnapshot.rng | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/docs/schemas/domainsnapshot.rng b/docs/schemas/domainsnapshot.rng
index 7b46df1..169fcfb 100644
--- a/docs/schemas/domainsnapshot.rng
+++ b/docs/schemas/domainsnapshot.rng
@@ -124,16 +124,7 @@
             </attribute>
           </optional>
           <interleave>
-            <optional>
-              <element name='driver'>
-                <optional>
-                  <attribute name='type'>
-                    <ref name='storageFormat'/>
-                  </attribute>
-                </optional>
-                <empty/>
-              </element>
-            </optional>
+            <ref name='disksnapshotdriver'/>
             <optional>
               <element name='source'>
                 <optional>
@@ -150,4 +141,17 @@
     </element>
   </define>
 
+  <define name='disksnapshotdriver'>
+    <optional>
+      <element name='driver'>
+        <optional>
+          <attribute name='type'>
+            <ref name='storageFormat'/>
+          </attribute>
+        </optional>
+        <empty/>
+      </element>
+    </optional>
+  </define>
+
 </grammar>
-- 
1.9.0