[libxml2]Add libxml2 library

This commit is contained in:
zhoujiale
2026-07-26 16:57:28 +08:00
committed by zhoujiale
parent 0a44ec8a06
commit e841ac915d
3790 changed files with 668244 additions and 0 deletions
+35
View File
@@ -0,0 +1,35 @@
<element name="base"
xmlns="http://relaxng.org/ns/structure/1.0">
<choice>
<group>
<element name="data">
<value>firstValue</value>
</element>
<oneOrMore>
<element name="option">
<element name="value">
<text/>
</element>
<element name="label">
<text/>
</element>
</element>
</oneOrMore>
</group>
<group>
<element name="data">
<value>secondValue</value>
</element>
<oneOrMore>
<element name="option">
<element name="value">
<text/>
</element>
<element name="label">
<text/>
</element>
</element>
</oneOrMore>
</group>
</choice>
</element>
+12
View File
@@ -0,0 +1,12 @@
<?xml version="1.0" ?>
<base>
<data>secondValue</data>
<option>
<value>how</value>
<label>some</label>
</option>
<option>
<value>this</value>
<label>more</label>
</option>
</base>
+14
View File
@@ -0,0 +1,14 @@
<element name="number" xmlns="http://relaxng.org/ns/structure/1.0">
<attribute name="val">
<list>
<oneOrMore>
<choice>
<value>1</value>
<value>2</value>
<value>3</value>
</choice>
</oneOrMore>
</list>
</attribute>
<text/>
</element>
+1
View File
@@ -0,0 +1 @@
<number val="a 1 b 2 c 3" />
+1
View File
@@ -0,0 +1 @@
<number val="1 a 2 b 3 c" />
+1
View File
@@ -0,0 +1 @@
<number val="1 2 3" />
+16
View File
@@ -0,0 +1,16 @@
<element name="root" xmlns="http://relaxng.org/ns/structure/1.0">
<choice>
<element name="child">
<attribute name="type">
<value>Foo</value>
</attribute>
<!-- Define stuff that's only valid when type is "Foo" -->
</element>
<element name="child">
<attribute name="type">
<value>Bar</value>
</attribute>
<!-- Define stuff that's only valid when type is "Bar" -->
</element>
</choice>
</element>
+4
View File
@@ -0,0 +1,4 @@
<root>
<child type="Foo">
</child>
</root>
+4
View File
@@ -0,0 +1,4 @@
<root>
<child type="Bar">
</child>
</root>
+4
View File
@@ -0,0 +1,4 @@
<root>
<child type="">
</child>
</root>
+21
View File
@@ -0,0 +1,21 @@
<?xml version="1.0"?>
<grammar ns="http://www.example.com/choice"
xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="doc" ns="">
<ref name="elem"/>
<optional>
<ref name="elem"/>
<optional>
<ref name="elem"/>
</optional>
</optional>
</element>
</start>
<define name="elem">
<element name="elem" ns="">
<text/>
</element>
</define>
</grammar>
+6
View File
@@ -0,0 +1,6 @@
<?xml version="1.0"?>
<doc>
<elem/>
<elem/>
<elem/>
</doc>
+3
View File
@@ -0,0 +1,3 @@
<?xml version="1.0"?>
<doc>
</doc>
+4
View File
@@ -0,0 +1,4 @@
<?xml version="1.0"?>
<doc>
<elem/>
</doc>
+5
View File
@@ -0,0 +1,5 @@
<?xml version="1.0"?>
<doc>
<elem/>
<elem/>
</doc>
+7
View File
@@ -0,0 +1,7 @@
<?xml version="1.0"?>
<doc>
<elem/>
<elem/>
<elem/>
<elem/>
</doc>
+14
View File
@@ -0,0 +1,14 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element>
<anyName>
<except>
<nsName ns="http://bar.com/"/>
<nsName ns="http://foo.com/"/>
</except>
</anyName>
<empty/>
</element>
</start>
</grammar>
+1
View File
@@ -0,0 +1 @@
<foo xmlns="http://foo.com/"/>
+1
View File
@@ -0,0 +1 @@
<foo/>
+1
View File
@@ -0,0 +1 @@
<foo xmlns="http://foo.com/"/>
+11
View File
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar ns="" xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="t">
<ref name="tcont"/>
</element>
</start>
<define name="tcont">
<text/>
</define>
</grammar>
+8
View File
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar ns="" xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="root">
<externalRef href="595792-ext.rng"/>
</element>
</start>
</grammar>
+4
View File
@@ -0,0 +1,4 @@
<?xml version="1.0"?>
<root>
<t>foo</t>
</root>
+16
View File
@@ -0,0 +1,16 @@
<?xml version="1.0"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="test" ns="http://example.com/1/">
<zeroOrMore>
<attribute>
<choice>
<nsName ns="http://example.com/1/"/>
<nsName ns="http://example.com/2/"/>
</choice>
<text/>
</attribute>
</zeroOrMore>
</element>
</start>
</grammar>
+2
View File
@@ -0,0 +1,2 @@
<ex1:test xmlns:ex1="http://example.com/1/"
ex1:foo="bar"/>
+3
View File
@@ -0,0 +1,3 @@
<ex1:test xmlns:ex1="http://example.com/1/"
xmlns:ex3="http://example.com/3/"
ex3:foo="bar"/>
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+229
View File
@@ -0,0 +1,229 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
OASIS OpenDocument v1.0
Relax-NG Schema
** It's only a very small sub-set of the schema, meant for debugging text-notes-configuration element **
-->
<grammar
xmlns="http://relaxng.org/ns/structure/1.0"
xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0"
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0"
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0"
xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0"
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0"
xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0"
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0"
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0"
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0"
xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0"
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0"
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0"
xmlns:anim="urn:oasis:names:tc:opendocument:xmlns:animation:1.0"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:math="http://www.w3.org/1998/Math/MathML"
xmlns:xforms="http://www.w3.org/2002/xforms"
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0"
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0"
xmlns:smil="urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0"
>
<define name="office-process-content">
<optional>
<attribute name="office:process-content" a:defaultValue="true">
<ref name="boolean"/>
</attribute>
</optional>
</define>
<start>
<choice>
<ref name="office-document-styles"/>
</choice>
</start>
<define name="office-document-styles">
<element name="office:document-styles">
<ref name="office-document-common-attrs"/>
<ref name="office-styles"/>
</element>
</define>
<define name="office-document-common-attrs" combine="interleave">
<optional>
<attribute name="office:version">
<ref name="string"/>
</attribute>
</optional>
</define>
<define name="office-styles">
<optional>
<element name="office:styles">
<interleave>
<zeroOrMore>
<ref name="text-notes-configuration"/>
</zeroOrMore>
</interleave>
</element>
</optional>
</define>
<define name="text-notes-configuration">
<element name="text:notes-configuration">
<ref name="text-notes-configuration-content"/>
</element>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<ref name="text-note-class"/>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:citation-style-name">
<ref name="styleNameRef"/>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:citation-body-style-name">
<ref name="styleNameRef"/>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:default-style-name">
<ref name="styleNameRef"/>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:master-page-name">
<ref name="styleNameRef"/>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:start-value">
<ref name="nonNegativeInteger"/>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<ref name="common-num-format-prefix-suffix-attlist"/>
<optional>
<ref name="common-num-format-attlist"/>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:start-numbering-at">
<choice>
<value>document</value>
<value>chapter</value>
<value>page</value>
</choice>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<attribute name="text:footnotes-position">
<choice>
<value>text</value>
<value>page</value>
<value>section</value>
<value>document</value>
</choice>
</attribute>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<element name="text:note-continuation-notice-forward">
<text/>
</element>
</optional>
</define>
<define name="text-notes-configuration-content" combine="interleave">
<optional>
<element name="text:note-continuation-notice-backward">
<text/>
</element>
</optional>
</define>
<define name="common-num-format-prefix-suffix-attlist" combine="interleave">
<optional>
<attribute name="style:num-prefix">
<ref name="string"/>
</attribute>
</optional>
<optional>
<attribute name="style:num-suffix">
<ref name="string"/>
</attribute>
</optional>
</define>
<define name="common-num-format-attlist" combine="interleave">
<choice>
<attribute name="style:num-format">
<choice>
<value>1</value>
<value>i</value>
<value>I</value>
<ref name="string"/>
<empty/>
</choice>
</attribute>
<group>
<attribute name="style:num-format">
<choice>
<value>a</value>
<value>A</value>
</choice>
</attribute>
<ref name="style-num-letter-sync-attlist"/>
</group>
<empty/>
</choice>
</define>
<define name="style-num-letter-sync-attlist" combine="interleave">
<optional>
<attribute name="style:num-letter-sync">
<ref name="boolean"/>
</attribute>
</optional>
</define>
<define name="text-note-class">
<attribute name="text:note-class">
<choice>
<value>footnote</value>
<value>endnote</value>
</choice>
</attribute>
</define>
<define name="styleNameRef">
<choice>
<data type="NCName"/>
<empty/>
</choice>
</define>
<define name="nonNegativeInteger">
<data type="nonNegativeInteger"/>
</define>
<define name="boolean">
<choice>
<value>true</value>
<value>false</value>
</choice>
</define>
<define name="string">
<data type="string"/>
</define>
</grammar>
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<office:document-styles xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" office:version="1.0">
<office:styles>
<text:notes-configuration text:note-class="endnote" style:num-format="1" text:start-value="0"/>
</office:styles>
</office:document-styles>
+26
View File
@@ -0,0 +1,26 @@
<?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
<x:xmpmeta xmlns:x="adobe:ns:meta/">
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:pdf="http://ns.adobe.com/pdf/1.3/" xmlns:xmp="http://ns.adobe.com/xap/1.0/" rdf:about="">
<dc:format>application/pdf</dc:format>
<dc:language>
<rdf:Bag>
<rdf:li>x-unknown</rdf:li>
</rdf:Bag>
</dc:language>
<dc:date>
<rdf:Seq>
<rdf:li>2019-03-23T16:51:05Z</rdf:li>
</rdf:Seq>
</dc:date>
<pdf:Producer>Apache FOP Version SVN branches/fop-2_1</pdf:Producer>
<xmp:MetadataDate>2019-03-23T16:51:05Zddd</xmp:MetadataDate>
<pdf:PDFVersion>1.4</pdf:PDFVersion>
<pdf:Trapped>true</pdf:Trapped>
<xmp:CreatorTool>Apache FOP Version SVN branches/fop-2_1</xmp:CreatorTool>
<pdf:Ignore>true</pdf:Ignore>
<xmp:CreateDate>2019-03-23T16:51:05Z</xmp:CreateDate>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
<?xpacket end="r"?>
+24
View File
@@ -0,0 +1,24 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="addressBook">
<zeroOrMore>
<element name="card">
<ref name="cardContent"/>
</element>
</zeroOrMore>
</element>
</start>
<define name="cardContent">
<element name="name">
<text/>
</element>
<element name="email">
<text/>
</element>
</define>
</grammar>
+16
View File
@@ -0,0 +1,16 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0" >
<start>
<element name="foo">
<attribute>
<choice>
<name>alpha</name>
<name>bravo</name>
</choice>
<choice>
<value>none</value>
<value>all</value>
</choice>
</attribute>
</element>
</start>
</grammar>
@@ -0,0 +1 @@
<foo alpha="all"/>
+15
View File
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element>
<choice>
<choice>
<name>a</name>
<name>b</name>
</choice>
<name>c</name>
</choice>
<empty/>
</element>
</start>
</grammar>
+1
View File
@@ -0,0 +1 @@
<b/>
+15
View File
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element>
<choice>
<name>c</name>
<choice>
<name>a</name>
<name>b</name>
</choice>
</choice>
<empty/>
</element>
</start>
</grammar>
+1
View File
@@ -0,0 +1 @@
<b/>
+1
View File
@@ -0,0 +1 @@
<foo
+1
View File
@@ -0,0 +1 @@
<doc/>
+25
View File
@@ -0,0 +1,25 @@
<?xml version="1.0"?>
<element xmlns="http://relaxng.org/ns/structure/1.0" name="device">
<choice>
<group>
<attribute name="link">
<value>ethernet</value>
</attribute>
<optional>
<element name="ethernet-element">
<text/>
</element>
</optional>
</group>
<group>
<attribute name="link">
<value>serial</value>
</attribute>
<optional>
<element name="serial-element">
<text/>
</element>
</optional>
</group>
</choice>
</element>
+2
View File
@@ -0,0 +1,2 @@
<device link="ethernet">
</device>
+2
View File
@@ -0,0 +1,2 @@
<device link="serial">
</device>
+3
View File
@@ -0,0 +1,3 @@
<device link="ethernet">
<ethernet-element/>
</device>
+3
View File
@@ -0,0 +1,3 @@
<device link="serial">
<serial-element/>
</device>
+2
View File
@@ -0,0 +1,2 @@
<device link="unknown">
</device>
+3
View File
@@ -0,0 +1,3 @@
<device link="ethernet">
<serial-element/>
</device>
+3
View File
@@ -0,0 +1,3 @@
<device link="serial">
<ethernet-element/>
</device>
+3
View File
@@ -0,0 +1,3 @@
<device link="ethernet">
<unknown-element/>
</device>
+3
View File
@@ -0,0 +1,3 @@
<device link="unknown">
<unknown-element/>
</device>
+8
View File
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8" ?>
<element name="number" xmlns="http://relaxng.org/ns/structure/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<attribute name="att1">
<value type="integer"> 1 </value>
</attribute>
</element>
+3
View File
@@ -0,0 +1,3 @@
<?xml version="1.0" ?>
<number att1="x"></number>
+177
View File
@@ -0,0 +1,177 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<ref name="comps"/>
</start>
<define name="package-name">
<text/>
</define>
<define name="group-name">
<text/>
</define>
<define name="lang">
<text/>
</define>
<define name="description-text">
<text/>
</define>
<define name="comps">
<element name="comps">
<oneOrMore>
<ref name="group"/>
</oneOrMore>
<ref name="grouphierarchy"/>
<oneOrMore>
<ref name="package"/>
</oneOrMore>
</element>
</define>
<define name="group">
<element name="group">
<element name="id">
<ref name="group-name"/>
</element>
<interleave>
<ref name="names"/>
<optional>
<element name="default">
<choice>
<value>true</value>
<value>false</value>
</choice>
</element>
</optional>
<optional>
<ref name="descriptions"/>
</optional>
<optional>
<element name="uservisible">
<choice>
<value>true</value>
<value>false</value>
</choice>
</element>
</optional>
<optional>
<element name="langonly">
<ref name="lang"/>
</element>
</optional>
</interleave>
<optional>
<element name="grouplist">
<zeroOrMore>
<element name="groupreq">
<ref name="group-name"/>
</element>
</zeroOrMore>
<zeroOrMore>
<element name="metapkg">
<attribute name="type">
<choice>
<value>default</value>
<!-- <value>mandatory</value> ?? -->
<value>optional</value>
</choice>
</attribute>
<ref name="package-name"/>
</element>
</zeroOrMore>
</element>
</optional>
<optional>
<element name="packagelist">
<oneOrMore>
<element name="packagereq">
<attribute name="type">
<choice>
<value>default</value>
<value>mandatory</value>
<value>optional</value>
</choice>
</attribute>
<optional>
<attribute name="requires">
<ref name="package-name"/>
</attribute>
</optional>
<ref name="package-name"/>
</element>
</oneOrMore>
</element>
</optional>
</element>
</define>
<define name="grouphierarchy">
<element name="grouphierarchy">
<oneOrMore>
<ref name="category"/>
</oneOrMore>
</element>
</define>
<define name="category">
<element name="category">
<ref name="names"/>
<optional>
<element name="subcategories">
<oneOrMore>
<element name="subcategory">
<ref name="package-name"/>
</element>
</oneOrMore>
</element>
</optional>
</element>
</define>
<define name="package">
<element name="package">
<element name="name">
<ref name="package-name"/>
</element>
<element name="dependencylist">
<zeroOrMore>
<element name="dependency">
<ref name="package-name"/>
</element>
</zeroOrMore>
</element>
</element>
</define>
<define name="names">
<element name="name">
<ref name="description-text"/>
</element>
<zeroOrMore>
<element name="name">
<attribute name="xml:lang">
<ref name="lang"/>
</attribute>
<ref name="description-text"/>
</element>
</zeroOrMore>
</define>
<define name="descriptions">
<element name="description">
<ref name="description-text"/>
</element>
<zeroOrMore>
<element name="description">
<attribute name="xml:lang">
<ref name="lang"/>
</attribute>
<ref name="description-text"/>
</element>
</zeroOrMore>
</define>
</grammar>
File diff suppressed because it is too large Load Diff
+11
View File
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<include href="demo2.rng">
<define name="TEI.prose"><ref name="INCLUDE"/></define>
</include>
</grammar>
+1
View File
@@ -0,0 +1 @@
<TEI.2>hello</TEI.2>
+23
View File
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0" xmlns:t="http://www.thaiopensource.com/ns/annotations" xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<start>
<ref name="TEI.2"/>
</start>
<define name="IGNORE">
<notAllowed/>
</define>
<define name="INCLUDE">
<empty/>
</define>
<include href="demo3.rng"/>
<define name="TEI.2">
<element name="TEI.2">
<text/>
</element>
</define>
</grammar>
+8
View File
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0" xmlns:t="http://www.thaiopensource.com/ns/annotations" xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<define name="TEI.prose" combine="interleave">
<ref name="IGNORE"/>
</define>
</grammar>
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+16
View File
@@ -0,0 +1,16 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<ref name="top"/>
</start>
<define name="empty">
<empty/>
</define>
<define name="top">
<element name="top">
<ref name="empty"/>
<element name="a">
<text/>
</element>
</element>
</define>
</grammar>
+3
View File
@@ -0,0 +1,3 @@
<top>
<a/>
</top>
+18
View File
@@ -0,0 +1,18 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<ref name="top"/>
</start>
<define name="empty">
<empty/>
</define>
<define name="top">
<element name="top">
<choice>
<ref name="empty"/>
<element name="a">
<text/>
</element>
</choice>
</element>
</define>
</grammar>
+3
View File
@@ -0,0 +1,3 @@
<top>
<a/>
</top>
+2
View File
@@ -0,0 +1,2 @@
<top>
</top>
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<include href="include-limit_1.rng"/>
</grammar>
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<include href="include-limit_2.rng"/>
</grammar>
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<include href="include-limit_3.rng"/>
</grammar>
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="root">
<empty/>
</element>
</start>
</grammar>
+5
View File
@@ -0,0 +1,5 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<notAllowed/>
</start>
</grammar>
+11
View File
@@ -0,0 +1,11 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<include href="include0.inc">
<div>
<start>
<element name="root">
<empty/>
</element>
</start>
</div>
</include>
</grammar>
+1
View File
@@ -0,0 +1 @@
<root/>
+12
View File
@@ -0,0 +1,12 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<include href="include1-1.inc">
<start>
<notAllowed/>
</start>
</include>
<start combine="choice">
<element name="b">
<empty/>
</element>
</start>
</grammar>
+7
View File
@@ -0,0 +1,7 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<element name="c">
<empty/>
</element>
</start>
</grammar>
+12
View File
@@ -0,0 +1,12 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<include href="include1-0.inc">
<start>
<notAllowed/>
</start>
</include>
<start combine="choice">
<element name="a">
<empty/>
</element>
</start>
</grammar>
+1
View File
@@ -0,0 +1 @@
<a/>
+20
View File
@@ -0,0 +1,20 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<ref name="inline"/>
</start>
<define name="inline">
<zeroOrMore>
<choice>
<text/>
<element name="code">
<ref name="inline"/>
</element>
<element name="em">
<ref name="inline"/>
</element>
<!-- etc -->
</choice>
</zeroOrMore>
</define>
</grammar>
+21
View File
@@ -0,0 +1,21 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<define name="inline">
<zeroOrMore>
<ref name="inline.class"/>
</zeroOrMore>
</define>
<define name="inline.class">
<choice>
<text/>
<element name="bold">
<ref name="inline"/>
</element>
<element name="italic">
<ref name="inline"/>
</element>
</choice>
</define>
</grammar>
+22
View File
@@ -0,0 +1,22 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<define name="inline">
<zeroOrMore>
<choice>
<text/>
<element name="bold">
<ref name="inline"/>
</element>
<element name="italic">
<ref name="inline"/>
</element>
<ref name="inline.extra"/>
</choice>
</zeroOrMore>
</define>
<define name="inline.extra">
<notAllowed/>
</define>
</grammar>
+24
View File
@@ -0,0 +1,24 @@
<element name="addressBook" xmlns="http://relaxng.org/ns/structure/1.0">
<zeroOrMore>
<element name="card">
<interleave>
<zeroOrMore>
<element name="name">
<text/>
</element>
<element name="email">
<text/>
</element>
</zeroOrMore>
<zeroOrMore>
<element name="company">
<text/>
</element>
<element name="email">
<text/>
</element>
</zeroOrMore>
</interleave>
</element>
</zeroOrMore>
</element>
+15
View File
@@ -0,0 +1,15 @@
<element name="doc" xmlns="http://relaxng.org/ns/structure/1.0">
<interleave>
<element name="a">
<empty/>
</element>
<zeroOrMore>
<element name="b">
<empty/>
</element>
</zeroOrMore>
</interleave>
<element name="c">
<empty/>
</element>
</element>
File diff suppressed because it is too large Load Diff
+23
View File
@@ -0,0 +1,23 @@
<domain type='xen' id='6'>
<name>pvtest</name>
<uuid>596a5d2171f48fb2e068e2386a5c413e</uuid>
<os>
<type>linux</type>
<kernel>/var/lib/xen/vmlinuz.2Dn2YT</kernel>
<initrd>/var/lib/xen/initrd.img.0u-Vhq</initrd>
<cmdline> method=http://download.fedora.devel.redhat.com/pub/fedora/linux/core/test/5.91/x86_64/os </cmdline>
</os>
<memory>430080</memory>
<vcpu>2</vcpu>
<on_poweroff>destroy</on_poweroff>
<on_reboot>destroy</on_reboot>
<on_crash>destroy</on_crash>
<devices>
<disk type='file' device='disk'>
<driver name='file'/>
<source file='/root/some.img'/>
<target dev='xvda'/>
</disk>
<graphics type='vnc' port='-1' autoport='yes' listen="127.0.0.1" passwd="123456" keymap="ja"/>
</devices>
</domain>
+23
View File
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar
xmlns="http://relaxng.org/ns/structure/1.0"
xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<define name="pattern1">
<data type="string">
<param name="pattern">-?([0-9]+(\.[0-9]*)?|\.[0-9]+)</param>
</data>
</define>
<start>
<element name="elem1">
<attribute name="attr1">
<list>
<ref name="pattern1"/>
</list>
</attribute>
</element>
</start>
</grammar>
+1
View File
@@ -0,0 +1 @@
<elem1 attr1="0"/>
+1
View File
@@ -0,0 +1 @@
<elem1 attr1="a"/>
+8
View File
@@ -0,0 +1,8 @@
<group xmlns="http://relaxng.org/ns/structure/1.0">
<element name="a">
<text/>
</element>
<element name="b">
<text/>
</element>
</group>
+9
View File
@@ -0,0 +1,9 @@
<group xmlns="http://relaxng.org/ns/structure/1.0">
<element name="c">
<text/>
</element>
<element name="d">
<text/>
</element>
</group>
+11
View File
@@ -0,0 +1,11 @@
<?xml version="1.0"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<start>
<element name="test">
<data type="token">
<param name="pattern">[a-z]+</param>
</data>
</element>
</start>
</grammar>
+1
View File
@@ -0,0 +1 @@
<test> ooo </test>
+96
View File
@@ -0,0 +1,96 @@
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
ns="http://relaxng.org/ns/proofsystem">
<start>
<element name="proofSystem">
<oneOrMore>
<element name="rule">
<attribute name="name"/>
<zeroOrMore>
<ref name="antecedent"/>
</zeroOrMore>
<ref name="consequent"/>
</element>
</oneOrMore>
</element>
</start>
<define name="formula">
<element name="formula">
<choice>
<ref name="judgement"/>
<ref name="expr"/>
</choice>
</element>
</define>
<define name="consequent">
<ref name="judgement"/>
</define>
<define name="antecedent">
<ref name="judgement"/>
</define>
<define name="judgement">
<choice>
<element name="judgement">
<attribute name="name"/>
<zeroOrMore>
<ref name="expr"/>
</zeroOrMore>
</element>
<element name="not">
<ref name="judgement"/>
</element>
</choice>
</define>
<define name="expr">
<choice>
<element name="var">
<attribute name="range"/>
<optional>
<attribute name="index"/>
</optional>
<optional>
<attribute name="sub"/>
</optional>
</element>
<element name="function">
<attribute name="name"/>
<zeroOrMore>
<ref name="expr"/>
</zeroOrMore>
</element>
<element name="element">
<attribute name="name"/>
<zeroOrMore>
<element name="attribute">
<attribute name="name"/>
<ref name="expr"/>
</element>
</zeroOrMore>
<optional>
<ref name="context"/>
</optional>
<zeroOrMore>
<ref name="expr"/>
</zeroOrMore>
</element>
<element name="group">
<zeroOrMore>
<ref name="expr"/>
</zeroOrMore>
</element>
<element name="string"><text/></element>
</choice>
</define>
<define name="context">
<element name="context">
<ref name="expr"/>
</element>
</define>
</grammar>
+13
View File
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<ref name="e2"/>
</start>
<define name="e2">
<element name="e2">
<element name="e3">
<text/>
</element>
</element>
</define>
</grammar>
+16
View File
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0">
<start>
<ref name="root"/>
</start>
<define name="root">
<element name="root">
<interleave>
<element name="e1">
<text/>
</element>
<externalRef href="rngbug-001.ext"/>
</interleave>
</element>
</define>
</grammar>
+6
View File
@@ -0,0 +1,6 @@
<root>
<e1>x</e1>
<e2>
<e3>y</e3>
</e2>
</root>
@@ -0,0 +1,36 @@
<!-- RelaxNG: file:/V:/libxml2/test/relaxng/simplifyChoiceNotAllowed.rng -->
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<start>
<element name="_">
<element>
<name>entryWithoutRef</name>
<oneOrMore>
<choice>
<element>
<name>form</name>
<empty/>
</element>
<notAllowed/>
</choice>
</oneOrMore>
</element>
<element>
<name>entryWithRef</name>
<oneOrMore>
<choice>
<element>
<name>form</name>
<empty/>
</element>
<ref name="fancyNameforNotAllowed"/>
</choice>
</oneOrMore>
<empty/>
</element>
</element>
</start>
<define name="fancyNameforNotAllowed">
<notAllowed/>
</define>
</grammar>
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<_>
<entryWithoutRef>
<form/>
<!-- The second element should not be reported as an error -->
<form/>
<notAllowed/>
</entryWithoutRef>
<entryWithRef>
<form/>
<!-- The second element should not be reported as an error -->
<form/>
<notAllowed/>
</entryWithRef>
</_>
+60
View File
@@ -0,0 +1,60 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Id: spec.rng,v 1.3 2001/10/23 05:54:24 jjc Exp $ -->
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
xmlns:p="http://relaxng.org/ns/proofsystem">
<start>
<grammar>
<include href="docbook.rng"/>
<define name="synop.class" combine="choice">
<choice>
<parentRef name="rngref"/>
<parentRef name="grammarref"/>
<grammar>
<include href="proofsystem.rng"/>
<start combine="choice">
<ref name="formula"/>
</start>
</grammar>
</choice>
</define>
<define name="tech.char.class" combine="choice">
<parentRef name="terms"/>
</define>
</grammar>
</start>
<define name="rngref">
<element name="rngref">
<attribute name="src">
<data type="anyURI"/>
</attribute>
</element>
</define>
<define name="grammarref">
<element name="grammarref">
<attribute name="src">
<data type="anyURI"/>
</attribute>
</element>
</define>
<define name="terms">
<grammar>
<include href="proofsystem.rng">
<start>
<choice>
<ref name="expr"/>
<ref name="judgement"/>
<ref name="context"/>
</choice>
</start>
</include>
</grammar>
</define>
</grammar>
+14
View File
@@ -0,0 +1,14 @@
<?xml version="1.0"?>
<element name="foo"
xmlns="http://relaxng.org/ns/structure/1.0"
xmlns:a="http://relaxng.org/ns/annotation/1.0"
xmlns:ex1="http://www.example.com/n1"
xmlns:ex2="http://www.example.com/n2">
<a:documentation>A foo element.</a:documentation>
<element name="ex1:bar1">
<empty/>
</element>
<element name="ex2:bar2">
<empty/>
</element>
</element>
+3
View File
@@ -0,0 +1,3 @@
<?xml version="1.0"?>
<foo><pre1:bar1 xmlns:pre1="http://www.example.com/n1"/><pre2:bar2 xmlns:pre2="http://www.example.com/n2"/></foo>
File diff suppressed because it is too large Load Diff

Some files were not shown because too many files have changed in this diff Show More