RelaxNG/publiset.rng
changeset 30 c0f9e813c039
parent 29 0bd36d3b6a5a
child 34 c51d5097d065
equal deleted inserted replaced
29:0bd36d3b6a5a 30:c0f9e813c039
    75     <optional>
    75     <optional>
    76       <ref name="composition.head"/>
    76       <ref name="composition.head"/>
    77     </optional>
    77     </optional>
    78     <oneOrMore>
    78     <oneOrMore>
    79       <choice>
    79       <choice>
       
    80         <ref name="composition.division"/>
    80         <ref name="composition.file"/>
    81         <ref name="composition.file"/>
    81         <ref name="composition.division"/>
       
    82       </choice>
    82       </choice>
    83     </oneOrMore>
    83     </oneOrMore>
    84   </define>
    84   </define>
    85   <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ selection ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
    85   <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ selection ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
    86   <define name="selection">
    86   <define name="selection">
    93     <interleave>
    93     <interleave>
    94       <ref name="selection.id.attribute"/>
    94       <ref name="selection.id.attribute"/>
    95       <optional>
    95       <optional>
    96         <ref name="path.attribute"/>
    96         <ref name="path.attribute"/>
    97       </optional>
    97       </optional>
    98       <optional>
       
    99         <ref name="xpath.attribute"/>
       
   100       </optional>
       
   101     </interleave>
    98     </interleave>
   102   </define>
    99   </define>
   103   <define name="selection.id.attribute">
   100   <define name="selection.id.attribute">
   104     <attribute name="xml:id">
   101     <attribute name="xml:id">
   105       <data type="ID"/>
   102       <data type="ID"/>
   109     <optional>
   106     <optional>
   110       <ref name="selection.head"/>
   107       <ref name="selection.head"/>
   111     </optional>
   108     </optional>
   112     <oneOrMore>
   109     <oneOrMore>
   113       <choice>
   110       <choice>
       
   111         <ref name="selection.division"/>
   114         <ref name="selection.file"/>
   112         <ref name="selection.file"/>
   115         <ref name="selection.division"/>
   113         <ref name="link"/>
   116       </choice>
   114       </choice>
   117     </oneOrMore>
   115     </oneOrMore>
   118   </define>
   116   </define>
   119   <!--
   117   <!--
   120     =============================================================================
   118     =============================================================================
   330       </optional>
   328       </optional>
   331       <ref name="remap.attributes"/>
   329       <ref name="remap.attributes"/>
   332     </interleave>
   330     </interleave>
   333   </define>
   331   </define>
   334   <define name="selection.division.attributes">
   332   <define name="selection.division.attributes">
   335     <interleave>
   333     <optional>
   336       <optional>
   334       <ref name="path.attribute"/>
   337         <ref name="path.attribute"/>
   335     </optional>
   338       </optional>
       
   339       <optional>
       
   340         <ref name="xpath.attribute"/>
       
   341       </optional>
       
   342     </interleave>
       
   343   </define>
   336   </define>
   344   <define name="composition.division.content">
   337   <define name="composition.division.content">
   345     <optional>
   338     <optional>
   346       <ref name="composition.head"/>
   339       <ref name="composition.head"/>
   347     </optional>
   340     </optional>
   358     </optional>
   351     </optional>
   359     <oneOrMore>
   352     <oneOrMore>
   360       <choice>
   353       <choice>
   361         <ref name="selection.division"/>
   354         <ref name="selection.division"/>
   362         <ref name="selection.file"/>
   355         <ref name="selection.file"/>
       
   356         <ref name="link"/>
   363       </choice>
   357       </choice>
   364     </oneOrMore>
   358     </oneOrMore>
   365   </define>
   359   </define>
   366   <!--
   360   <!--
   367     =============================================================================
   361     =============================================================================
   370   -->
   364   -->
   371   <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ file ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
   365   <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ file ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
   372   <define name="composition.file">
   366   <define name="composition.file">
   373     <element name="file">
   367     <element name="file">
   374       <ref name="composition.file.attributes"/>
   368       <ref name="composition.file.attributes"/>
   375       <ref name="file.content"/>
       
   376     </element>
   369     </element>
   377   </define>
   370   </define>
   378   <define name="selection.file">
   371   <define name="selection.file">
   379     <element name="file">
   372     <element name="file">
   380       <ref name="selection.file.attributes"/>
   373       <ref name="selection.file.attributes"/>
   381       <ref name="file.content"/>
   374       <ref name="file.content"/>
   382     </element>
   375     </element>
   383   </define>
   376   </define>
   384   <define name="composition.file.attributes">
   377   <define name="composition.file.attributes">
   385     <interleave>
   378     <interleave>
       
   379       <ref name="name.attribute"/>
   386       <optional>
   380       <optional>
   387         <ref name="xpath.attribute"/>
   381         <ref name="xpath.attribute"/>
   388       </optional>
   382       </optional>
   389       <optional>
   383       <optional>
   390         <ref name="xslt.attribute"/>
   384         <ref name="xslt.attribute"/>
   391       </optional>
   385       </optional>
   392       <ref name="remap.attributes"/>
   386       <ref name="remap.attributes"/>
   393     </interleave>
   387     </interleave>
   394   </define>
   388   </define>
   395   <define name="selection.file.attributes">
   389   <define name="selection.file.attributes">
   396     <optional>
   390     <interleave>
   397       <ref name="xpath.attribute"/>
   391       <ref name="name.attribute"/>
   398     </optional>
   392       <optional>
       
   393         <ref name="uri.attribute"/>
       
   394       </optional>
       
   395     </interleave>
       
   396   </define>
       
   397   <define name="name.attribute">
       
   398     <attribute name="name">
       
   399       <data type="anyURI"/>
       
   400     </attribute>
       
   401   </define>
       
   402   <define name="uri.attribute">
       
   403     <attribute name="uri">
       
   404       <data type="anyURI"/>
       
   405     </attribute>
   399   </define>
   406   </define>
   400   <define name="file.content">
   407   <define name="file.content">
   401     <data type="anyURI"/>
   408     <ref name="inlines"/>
       
   409   </define>
       
   410   <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ link ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
       
   411   <define name="link">
       
   412     <element name="link">
       
   413       <ref name="link.attributes"/>
       
   414       <ref name="link.content"/>
       
   415     </element>
       
   416   </define>
       
   417   <define name="link.attributes">
       
   418     <ref name="uri.attribute"/>
       
   419   </define>
       
   420   <define name="link.content">
       
   421     <ref name="inlines"/>
   402   </define>
   422   </define>
   403   <!--
   423   <!--
   404     =============================================================================
   424     =============================================================================
   405                                     INLINE LEVEL
   425                                     INLINE LEVEL
   406     =============================================================================
   426     =============================================================================