Moving network route to the network common schema will allow reusing it.
---
docs/schemas/network.rng | 20 +-------------------
docs/schemas/networkcommon.rng | 22 ++++++++++++++++++++++
2 files changed, 23 insertions(+), 19 deletions(-)
diff --git a/docs/schemas/network.rng b/docs/schemas/network.rng
index 9a7d156..63d81c1 100644
--- a/docs/schemas/network.rng
+++ b/docs/schemas/network.rng
@@ -371,25 +371,7 @@
</zeroOrMore>
<!-- <route> element -->
<zeroOrMore>
- <!-- The (static) route element specifies a network address and gateway
- address to access that network. Both the network address and
- the gateway address must be specified. -->
- <element name="route">
- <optional>
- <attribute name="family"><ref
name="addr-family"/></attribute>
- </optional>
- <attribute name="address"><ref
name="ipAddr"/></attribute>
- <optional>
- <choice>
- <attribute name="netmask"><ref
name="ipv4Addr"/></attribute>
- <attribute name="prefix"><ref
name="ipPrefix"/></attribute>
- </choice>
- </optional>
- <attribute name="gateway"><ref
name="ipAddr"/></attribute>
- <optional>
- <attribute name="metric"><ref
name="unsignedInt"/></attribute>
- </optional>
- </element>
+ <ref name="routex"/>
</zeroOrMore>
</interleave>
</element>
diff --git a/docs/schemas/networkcommon.rng b/docs/schemas/networkcommon.rng
index e26b7f3..cbcae91 100644
--- a/docs/schemas/networkcommon.rng
+++ b/docs/schemas/networkcommon.rng
@@ -224,4 +224,26 @@
<param name='maxInclusive'>65535</param>
</data>
</define>
+
+ <!-- The (static) route element specifies a network address and gateway
+ address to access that network. Both the network address and
+ the gateway address must be specified. -->
+ <define name='routex'>
+ <element name="route">
+ <optional>
+ <attribute name="family"><ref
name="addr-family"/></attribute>
+ </optional>
+ <attribute name="address"><ref
name="ipAddr"/></attribute>
+ <optional>
+ <choice>
+ <attribute name="netmask"><ref
name="ipv4Addr"/></attribute>
+ <attribute name="prefix"><ref
name="ipPrefix"/></attribute>
+ </choice>
+ </optional>
+ <attribute name="gateway"><ref
name="ipAddr"/></attribute>
+ <optional>
+ <attribute name="metric"><ref
name="unsignedInt"/></attribute>
+ </optional>
+ </element>
+ </define>
</grammar>
--
2.1.2