O'Reilly logo

XML: kurz & gut by Michael Fitzgerald, Simon St. Laurent

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

rng:parentRef

Verweist auf ein benanntes Muster in einer Eltern-Grammatik.

Beispiel für XML-Syntax

<grammar xmlns="http://relaxng.org/ns/structure/1.0">

<start>
 <choice>
  <ref name="typ" />
  <ref name="alt" />
 </choice>
</start>

<define name="typ">
 <element name="typ">
  <list>
   <choice>
    <value>html</value>
    <value>xhtml</value>
    <value>xml</value>
   </choice>
  </list>
 </element>
</define>

<define name="alt">
 <grammar>
  <start>
  <choice>
   <element name="methode">
    <list>
     <choice>
      <value>text</value>
<value>other</value>
     </choice>
    </list>
   </element>
   <parentRef name="typ"/>
  </choice>
  </start>
 </grammar>
</define>

</grammar>

Beispiel für kompakte Syntax

start = typ | alt typ = element typ { list { "html" | "xhtml" | "xml" } } alt = grammar { start = element methode ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required