<?xml version="1.0" encoding="utf-8"?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0"
         xmlns:tei="http://www.tei-c.org/ns/1.0"
         xmlns:teix="http://www.tei-c.org/ns/Examples"
         datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"><!--Schema generated 2025-08-28T16:49:00Z
Edition: P5 Version 4.10.1. Last updated on
        28th August 2025, revision 3cd82e7a3
This material is dual-licensed.
[http://creativecommons.org/licenses/by/3.0/] Distributed under a Creative Commons Attribution 3.0 Unported License.  [http://www.opensource.org/licenses/BSD-2-Clause] Copyright 2025 TEI Consortium. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. This software is provided by the copyright holders and contributors "as is" and any express or implied warranties, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose are disclaimed. In no event shall the copyright holder or contributors be liable for any direct, indirect, incidental, special, exemplary, or consequential damages (including, but not limited to, procurement of substitute goods or services; loss of use, data, or profits; or business interruption) however caused and on any theory of liability, whether in contract, strict liability, or tort (including negligence or otherwise) arising in any way out of the use of this software, even if advised of the possibility of such damage. TEI material can be licensed differently depending on the use you intend to make of it. Hence it is made available under both the CC+BY and BSD-2 licences. The CC+BY licence is generally appropriate for usages which treat TEI content as data or documentation. The BSD-2 licence is generally appropriate for usage of TEI content in a software environment. For further information or clarification, please contact the  TEI
          Consortium . Documentation of TEI and other XML markup languages--><!--Definitions from module tagdocs--><!--Set global predeclared macros--><!--Set predeclared macros--><!--0. predeclared macros--><!--1. classes-->
   <define name="att.translatable.attributes">
      <ref name="att.translatable.attribute.versionDate"/>
   </define>
   <define name="att.translatable.attribute.versionDate">
      <optional>
         <attribute name="versionDate">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies the date on which the source text was extracted and sent to the translator</a:documentation>
            <choice>
               <data type="date">
                  <param name="pattern">(19[789][0-9]|[2-9][0-9]{3}).*</param>
               </data>
               <data type="dateTime">
                  <param name="pattern">(19[789][0-9]|[2-9][0-9]{3}).*</param>
               </data>
            </choice>
         </attribute>
      </optional>
   </define>
   <define name="att.predicate.attributes">
      <ref name="att.predicate.attribute.predicate"/>
   </define>
   <define name="att.predicate.attribute.predicate">
      <optional>
         <attribute name="predicate">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the condition under which the element bearing this attribute applies, given as an XPath predicate expression.</a:documentation>
            <text/>
         </attribute>
      </optional>
   </define>
   <define name="att.repeatable.attributes">
      <ref name="att.repeatable.attribute.minOccurs"/>
      <ref name="att.repeatable.attribute.maxOccurs"/>
   </define>
   <define name="att.repeatable.attribute.minOccurs">
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="minOccurs"
                    a:defaultValue="1">
            <a:documentation>(minimum number of occurrences) indicates the smallest number of times this component may occur.</a:documentation>
            <data type="nonNegativeInteger"/>
         </attribute>
      </optional>
   </define>
   <define name="att.repeatable.attribute.maxOccurs">
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="maxOccurs"
                    a:defaultValue="1">
            <a:documentation>(maximum number of occurrences) indicates the largest number of times this component may occur.</a:documentation>
            <choice>
               <data type="nonNegativeInteger"/>
               <choice>
                  <value>unbounded</value>
                  <a:documentation/>
               </choice>
            </choice>
         </attribute>
      </optional>
   </define>
   <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
            id="att.repeatable-MINandMAXoccurs-constraint-rule-73">
      <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                xmlns:rng="http://relaxng.org/ns/structure/1.0"
                xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                xmlns:xi="http://www.w3.org/2001/XInclude"
                context="tei:*[ @minOccurs and @maxOccurs ]">
         <sch:let name="min" value="@minOccurs cast as xs:integer"/>
         <sch:let name="max"
                  value="if ( normalize-space( @maxOccurs ) eq 'unbounded') then -1 else @maxOccurs cast as xs:integer"/>
         <sch:assert test="$max eq -1 or $max ge $min">@maxOccurs should be greater than or equal to @minOccurs</sch:assert>
      </sch:rule>
      <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                xmlns:rng="http://relaxng.org/ns/structure/1.0"
                xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                xmlns:xi="http://www.w3.org/2001/XInclude"
                context="tei:*[ @minOccurs and not( @maxOccurs ) ]">
         <sch:assert test="@minOccurs cast as xs:integer lt 2">When @maxOccurs is not specified, @minOccurs must be 0 or 1</sch:assert>
      </sch:rule>
   </pattern>
   <define name="model.contentPart">
      <choice>
         <ref name="classRef"/>
         <ref name="elementRef"/>
         <ref name="macroRef"/>
         <ref name="sequence"/>
         <ref name="alternate"/>
         <ref name="dataRef"/>
         <ref name="textNode"/>
         <ref name="anyElement"/>
         <ref name="empty"/>
      </choice>
   </define>
   <define name="model.contentPart_alternation">
      <choice>
         <ref name="classRef"/>
         <ref name="elementRef"/>
         <ref name="macroRef"/>
         <ref name="sequence"/>
         <ref name="alternate"/>
         <ref name="dataRef"/>
         <ref name="textNode"/>
         <ref name="anyElement"/>
         <ref name="empty"/>
      </choice>
   </define>
   <define name="model.contentPart_sequence">
      <ref name="classRef"/>
      <ref name="elementRef"/>
      <ref name="macroRef"/>
      <ref name="sequence"/>
      <ref name="alternate"/>
      <ref name="dataRef"/>
      <ref name="textNode"/>
      <ref name="anyElement"/>
      <ref name="empty"/>
   </define>
   <define name="model.contentPart_sequenceOptional">
      <optional>
         <ref name="classRef"/>
      </optional>
      <optional>
         <ref name="elementRef"/>
      </optional>
      <optional>
         <ref name="macroRef"/>
      </optional>
      <optional>
         <ref name="sequence"/>
      </optional>
      <optional>
         <ref name="alternate"/>
      </optional>
      <optional>
         <ref name="dataRef"/>
      </optional>
      <optional>
         <ref name="textNode"/>
      </optional>
      <optional>
         <ref name="anyElement"/>
      </optional>
      <optional>
         <ref name="empty"/>
      </optional>
   </define>
   <define name="model.contentPart_sequenceOptionalRepeatable">
      <zeroOrMore>
         <ref name="classRef"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="elementRef"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="macroRef"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="sequence"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="alternate"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="dataRef"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="textNode"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="anyElement"/>
      </zeroOrMore>
      <zeroOrMore>
         <ref name="empty"/>
      </zeroOrMore>
   </define>
   <define name="model.contentPart_sequenceRepeatable">
      <oneOrMore>
         <ref name="classRef"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="elementRef"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="macroRef"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="sequence"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="alternate"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="dataRef"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="textNode"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="anyElement"/>
      </oneOrMore>
      <oneOrMore>
         <ref name="empty"/>
      </oneOrMore>
   </define>
   <define name="att.combinable.attributes">
      <ref name="att.deprecated.attributes"/>
      <ref name="att.combinable.attribute.mode"/>
   </define>
   <define name="att.combinable.attribute.mode">
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="mode"
                    a:defaultValue="add">
            <a:documentation>specifies the effect of this declaration on its parent object.</a:documentation>
            <choice>
               <value>add</value>
               <a:documentation>this declaration is part of the current definitions.</a:documentation>
               <value>delete</value>
               <a:documentation>the object with the same identifier (and namespace in the case of an element or attribute) as the current one is no longer part of the current definitions</a:documentation>
               <value>change</value>
               <a:documentation>this declaration changes the object of the same identifier (and namespace in the case of an element or attribute) in the current definition</a:documentation>
               <value>replace</value>
               <a:documentation>this declaration replaces the object with the same identifier (and namespace in the case of an element or attribute) in the current definition.</a:documentation>
            </choice>
         </attribute>
      </optional>
   </define>
   <define name="att.identified.attributes">
      <ref name="att.combinable.attributes"/>
      <ref name="att.identified.attribute.ident"/>
      <ref name="att.identified.attribute.predeclare"/>
      <ref name="att.identified.attribute.module"/>
   </define>
   <define name="att.identified.attribute.ident">
      <attribute name="ident">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies the identifier by which this element may be referenced.</a:documentation>
         <data type="Name"/>
      </attribute>
   </define>
   <define name="att.identified.attribute.predeclare">
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="predeclare"
                    a:defaultValue="false">
            <a:documentation>says whether this object should be predeclared in the tei infrastructure module.</a:documentation>
            <data type="boolean"/>
         </attribute>
      </optional>
   </define>
   <define name="att.identified.attribute.module">
      <optional>
         <attribute name="module">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a name for the module in which this object is to be declared.</a:documentation>
            <data type="NCName"/>
         </attribute>
      </optional>
   </define>
   <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
            id="att.identified-spec-in-module-constraint-rule-95">
      <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                xmlns:rng="http://relaxng.org/ns/structure/1.0"
                xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                xmlns:xi="http://www.w3.org/2001/XInclude"
                context="tei:elementSpec[@module]|tei:classSpec[@module]|tei:macroSpec[@module]">
         <sch:assert test="(not(ancestor::tei:schemaSpec | ancestor::tei:TEI | ancestor::tei:teiCorpus)) or (not(@module) or (not(//tei:moduleSpec) and not(//tei:moduleRef)) or (//tei:moduleSpec[@ident = current()/@module]) or (//tei:moduleRef[@key = current()/@module]))">
        Specification <sch:value-of select="@ident"/>: the value of the module attribute ("<sch:value-of select="@module"/>") 
should correspond to an existing module, via a moduleSpec or
      moduleRef</sch:assert>
      </sch:rule>
   </pattern>
   <define name="att.deprecated.attributes">
      <ref name="att.deprecated.attribute.validUntil"/>
   </define>
   <define name="att.deprecated.attribute.validUntil">
      <optional>
         <attribute name="validUntil">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">provides a date before which the construct being defined will not be removed.</a:documentation>
            <data type="date"/>
         </attribute>
      </optional>
   </define>
   <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
            id="att.deprecated-validUntil-deprecation-two-month-warning-constraint-rule-96">
      <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                xmlns:rng="http://relaxng.org/ns/structure/1.0"
                xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                xmlns:xi="http://www.w3.org/2001/XInclude"
                context="tei:*[@validUntil]">
         <sch:let name="advance_warning_period"
                  value="current-date() + xs:dayTimeDuration('P60D')"/>
         <sch:let name="me_phrase"
                  value="if (@ident) then concat('The ', @ident ) else concat('This ', local-name(.), ' of ', ancestor::tei:*[@ident][1]/@ident )"/>
         <sch:assert test="@validUntil cast as xs:date ge current-date()">
            <sch:value-of select="concat( $me_phrase, ' construct is outdated (as of ', @validUntil, '); ODD processors may ignore it, and its use is no longer supported' )"/>
         </sch:assert>
         <sch:assert role="warning"
                     test="@validUntil cast as xs:date ge $advance_warning_period">
            <sch:value-of select="concat( $me_phrase, ' construct becomes outdated on ', @validUntil )"/>
         </sch:assert>
      </sch:rule>
   </pattern>
   <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
            id="att.deprecated-validUntil-deprecation-should-be-explained-constraint-rule-97">
      <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                xmlns:rng="http://relaxng.org/ns/structure/1.0"
                xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                xmlns:xi="http://www.w3.org/2001/XInclude"
                context="tei:*[@validUntil][ not( self::tei:valDesc | self::tei:valList | self::tei:defaultVal | self::tei:remarks )]">
         <sch:assert test="child::tei:desc[ @type eq 'deprecationInfo']">
              A deprecated construct should include, whenever possible, an explanation, but this <sch:value-of select="name(.)"/> does not have a child &lt;desc type="deprecationInfo"&gt;</sch:assert>
      </sch:rule>
   </pattern>
   <define name="att.namespaceable.attributes">
      <ref name="att.namespaceable.attribute.ns"/>
   </define>
   <define name="att.namespaceable.attribute.ns">
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="ns"
                    a:defaultValue="http://www.tei-c.org/ns/1.0">
            <a:documentation>(namespace) specifies the namespace to which the element(s) being specified belongs.</a:documentation>
            <optional>
               <data type="anyURI">
                  <param name="pattern">\S+</param>
               </data>
            </optional>
         </attribute>
      </optional>
   </define>
   <!--2. elements-->
   <define name="altIdent">
      <element name="altIdent">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(alternate identifier) supplies the recommended XML name for an element, class, attribute, etc. in some language. [ ]</a:documentation>
         <ref name="altIdent.content"/>
         <ref name="altIdent.localattributes"/>
      </element>
   </define>
   <define name="altIdent.content">
      <data type="NCName"/>
   </define>
   <define name="altIdent.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.typed.attributes"/>
      <empty/>
   </define>
   <define name="alternate">
      <element name="alternate">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates that the constructs referenced by its children form an alternation. []</a:documentation>
         <ref name="alternate.content"/>
         <ref name="alternate.localattributes"/>
      </element>
   </define>
   <define name="alternate.content">
      <oneOrMore>
         <choice>
            <ref name="valList"/>
            <ref name="model.contentPart"/>
         </choice>
      </oneOrMore>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="alternate-alternatechilden-constraint-rule-76">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:alternate">
            <sch:assert test="count(*) gt 1">The alternate element must have at least two child elements</sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="alternate.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.repeatable.attributes"/>
      <empty/>
   </define>
   <define name="anyElement">
      <element name="anyElement">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates the presence of any elements in a content model. []</a:documentation>
         <ref name="anyElement.content"/>
         <ref name="anyElement.localattributes"/>
      </element>
   </define>
   <define name="anyElement.content">
      <empty/>
   </define>
   <define name="anyElement.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.repeatable.attributes"/>
      <optional>
         <attribute name="require">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a list of namespaces to one of which the permitted elements must belong.</a:documentation>
            <list>
               <oneOrMore>
                  <data type="anyURI">
                     <param name="pattern">\S+</param>
                  </data>
               </oneOrMore>
            </list>
         </attribute>
      </optional>
      <optional>
         <attribute name="except">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a list of namespaces or prefixed element names which are not permitted.</a:documentation>
            <list>
               <oneOrMore>
                  <choice>
                     <data type="anyURI">
                        <param name="pattern">[^/\s]+:\S*</param>
                     </data>
                     <data type="Name">
                        <param name="pattern">.+:.+</param>
                     </data>
                  </choice>
               </oneOrMore>
            </list>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="att">
      <element name="att">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(attribute) contains the name of an attribute appearing within running text. []</a:documentation>
         <ref name="att.content"/>
         <ref name="att.localattributes"/>
      </element>
   </define>
   <define name="att.content">
      <data type="Name"/>
   </define>
   <define name="att.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="scheme"
                    a:defaultValue="TEI">
            <a:documentation>(scheme) supplies an identifier for the scheme in which this name is defined.
Sample values include: 1] TEI (Text Encoding Initiative); 2] DBK (Docbook); 3] XX (unknown); 4] imaginary (imaginary); 5] XHTML (XHTML); 6] XML (XML); 7] XI (XI)</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="attDef">
      <element name="attDef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(attribute definition) contains the definition of a single attribute. []</a:documentation>
         <ref name="attDef.content"/>
         <ref name="attDef.localattributes"/>
      </element>
   </define>
   <define name="attDef.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identSynonyms"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <ref name="datatype"/>
         </optional>
         <zeroOrMore>
            <ref name="constraintSpec"/>
         </zeroOrMore>
         <optional>
            <ref name="defaultVal"/>
         </optional>
         <optional>
            <choice>
               <ref name="valList"/>
               <oneOrMore>
                  <ref name="valDesc"/>
               </oneOrMore>
            </choice>
         </optional>
         <zeroOrMore>
            <ref name="exemplum"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="remarks"/>
         </zeroOrMore>
      </group>
      <sch:ns xmlns="http://www.tei-c.org/ns/1.0"
              xmlns:rng="http://relaxng.org/ns/structure/1.0"
              xmlns:sch="http://purl.oclc.org/dsdl/schematron"
              xmlns:xi="http://www.w3.org/2001/XInclude"
              prefix="teix"
              uri="http://www.tei-c.org/ns/Examples"/>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="attDef-attDefContents-constraint-rule-89">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:attDef">
            <sch:assert test="ancestor::teix:egXML[ @valid eq 'feasible']                        or @mode eq 'change'                        or @mode eq 'delete'                        or tei:datatype                        or tei:valList[ @type eq 'closed']">
          Attribute: the definition of the @<sch:value-of select="@ident"/> attribute in the
          <sch:value-of select="ancestor::*[@ident][1]/@ident"/>
               <sch:value-of select="' '"/>
               <sch:value-of select="local-name(ancestor::*[@ident][1])"/> should
          have a closed valList or a datatype
        </sch:assert>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="attDef-noDefault4Required-constraint-rule-90">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:attDef[@usage eq 'req']">
            <sch:report test="tei:defaultVal">Since the @<sch:value-of select="@ident"/> attribute is required, it will always be specified. Thus the default value (of "<sch:value-of select="normalize-space(tei:defaultVal)"/>") will never be used. Either change the definition of the attribute so it is not required ("rec" or "opt"), or remove the defaultVal element.</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="attDef-defaultIsInClosedList-twoOrMore-constraint-rule-91">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:attDef[     tei:defaultVal                                      and tei:valList[ @type eq 'closed']                                      and tei:datatype[ @maxOccurs &gt; 1  or  @minOccurs &gt; 1  or  @maxOccurs eq 'unbounded']                                    ]">
            <sch:assert test="tokenize(normalize-space(tei:defaultVal),' ') = tei:valList/tei:valItem/@ident">In the <sch:value-of select="local-name(ancestor::*[@ident][1])"/> defining
        <sch:value-of select="ancestor::*[@ident][1]/@ident"/> the default value of the
        @<sch:value-of select="@ident"/> attribute is not among the closed list of possible
        values</sch:assert>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="attDef-defaultIsInClosedList-one-constraint-rule-92">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:attDef[     tei:defaultVal                                      and tei:valList[ @type eq 'closed']                                      and tei:datatype[                                             not(@maxOccurs)                                         or  ( if ( @maxOccurs castable as xs:integer ) then ( @maxOccurs cast as xs:integer eq 1 ) else false() )                                                      ]                                    ]">
            <sch:assert test="string(tei:defaultVal) = tei:valList/tei:valItem/@ident">In the <sch:value-of select="local-name(ancestor::*[@ident][1])"/> defining
        <sch:value-of select="ancestor::*[@ident][1]/@ident"/> the default value of the
        @<sch:value-of select="@ident"/> attribute is not among the closed list of possible
        values</sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="attDef.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <ref name="att.namespaceable.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="usage"
                    a:defaultValue="opt">
            <a:documentation>specifies the optionality of the attribute.</a:documentation>
            <choice>
               <value>req</value>
               <a:documentation>(required) </a:documentation>
               <value>rec</value>
               <a:documentation>(recommended) </a:documentation>
               <value>opt</value>
               <a:documentation>(optional) </a:documentation>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="attList">
      <element name="attList">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(attribute list) contains documentation for all the attributes associated with this element, as a series of <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;attDef&gt;</code> elements. [ ]</a:documentation>
         <ref name="attList.content"/>
         <ref name="attList.localattributes"/>
      </element>
   </define>
   <define name="attList.content">
      <oneOrMore>
         <choice>
            <ref name="attRef"/>
            <ref name="attDef"/>
            <ref name="attList"/>
         </choice>
      </oneOrMore>
   </define>
   <define name="attList.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="org"
                    a:defaultValue="group">
            <a:documentation>(organization) specifies whether only one (choice) or all (group) of the attributes in the list are available.</a:documentation>
            <choice>
               <value>group</value>
               <a:documentation>grouped</a:documentation>
               <value>choice</value>
               <a:documentation>alternated</a:documentation>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="attRef">
      <element name="attRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(attribute pointer) points to the definition of an attribute or group of attributes. []</a:documentation>
         <ref name="attRef.content"/>
         <ref name="attRef.localattributes"/>
      </element>
   </define>
   <define name="attRef.content">
      <empty/>
   </define>
   <define name="attRef.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="class">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the name of the attribute class</a:documentation>
            <data type="Name"/>
         </attribute>
      </optional>
      <optional>
         <attribute name="name">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the name of the attribute</a:documentation>
            <data type="Name"/>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="classRef">
      <element name="classRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">points to the specification for an attribute or model class which is to be included in a schema. []</a:documentation>
         <ref name="classRef.content"/>
         <ref name="classRef.localattributes"/>
      </element>
   </define>
   <define name="classRef.content">
      <empty/>
   </define>
   <define name="classRef.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.repeatable.attributes"/>
      <attribute name="key">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the identifier used for the required class within the source indicated.</a:documentation>
         <data type="NCName"/>
      </attribute>
      <optional>
         <attribute name="expand">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates how references to this class within a content model should be interpreted.</a:documentation>
            <choice>
               <value>alternation</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">any one member of the class may appear</a:documentation>
               <value>sequence</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a single occurrence of all members of the class may appear in sequence</a:documentation>
               <value>sequenceOptional</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a single occurrence of one or more members of the class may appear in sequence</a:documentation>
               <value>sequenceOptionalRepeatable</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">one or more occurrences of one or more members of the class may appear in sequence.</a:documentation>
               <value>sequenceRepeatable</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">one or more occurrences of all members of the class may appear in sequence</a:documentation>
            </choice>
         </attribute>
      </optional>
      <choice>
         <optional>
            <attribute name="include">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a list of class members which are to be included in the schema being defined.</a:documentation>
               <list>
                  <zeroOrMore>
                     <data type="NCName"/>
                  </zeroOrMore>
               </list>
            </attribute>
         </optional>
         <optional>
            <attribute name="except">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a list of class members which are to be excluded from the schema being defined.</a:documentation>
               <list>
                  <zeroOrMore>
                     <data type="NCName"/>
                  </zeroOrMore>
               </list>
            </attribute>
         </optional>
      </choice>
      <empty/>
   </define>
   <define name="classSpec">
      <element name="classSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(class specification) contains reference information for a TEI element class; that is a group of elements which appear together in content models, or which share some common attribute, or both. [ ]</a:documentation>
         <ref name="classSpec.content"/>
         <ref name="classSpec.localattributes"/>
      </element>
   </define>
   <define name="classSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identSynonyms"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <ref name="classes"/>
         </optional>
         <zeroOrMore>
            <ref name="constraintSpec"/>
         </zeroOrMore>
         <optional>
            <ref name="attList"/>
         </optional>
         <zeroOrMore>
            <ref name="exemplum"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="remarks"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="listRef"/>
         </zeroOrMore>
      </group>
   </define>
   <define name="classSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <ref name="att.typed.attribute.subtype"/>
      <attribute name="type">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates whether this is a model class or an attribute class</a:documentation>
         <choice>
            <value>model</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(content model) members of this class appear in the same content models</a:documentation>
            <value>atts</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(attributes) members of this class share common attributes</a:documentation>
         </choice>
      </attribute>
      <optional>
         <attribute name="generate">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates which alternation and sequence instantiations of a model class may be referenced. By default, all variations are permitted.</a:documentation>
            <list>
               <choice>
                  <value>alternation</value>
                  <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are alternatives</a:documentation>
                  <value>sequence</value>
                  <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are to be provided in sequence</a:documentation>
                  <value>sequenceOptional</value>
                  <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided, in sequence, but are optional</a:documentation>
                  <value>sequenceOptionalRepeatable</value>
                  <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence, but are optional.</a:documentation>
                  <value>sequenceRepeatable</value>
                  <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence</a:documentation>
               </choice>
               <optional>
                  <choice>
                     <value>alternation</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are alternatives</a:documentation>
                     <value>sequence</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are to be provided in sequence</a:documentation>
                     <value>sequenceOptional</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided, in sequence, but are optional</a:documentation>
                     <value>sequenceOptionalRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence, but are optional.</a:documentation>
                     <value>sequenceRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence</a:documentation>
                  </choice>
               </optional>
               <optional>
                  <choice>
                     <value>alternation</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are alternatives</a:documentation>
                     <value>sequence</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are to be provided in sequence</a:documentation>
                     <value>sequenceOptional</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided, in sequence, but are optional</a:documentation>
                     <value>sequenceOptionalRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence, but are optional.</a:documentation>
                     <value>sequenceRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence</a:documentation>
                  </choice>
               </optional>
               <optional>
                  <choice>
                     <value>alternation</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are alternatives</a:documentation>
                     <value>sequence</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are to be provided in sequence</a:documentation>
                     <value>sequenceOptional</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided, in sequence, but are optional</a:documentation>
                     <value>sequenceOptionalRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence, but are optional.</a:documentation>
                     <value>sequenceRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence</a:documentation>
                  </choice>
               </optional>
               <optional>
                  <choice>
                     <value>alternation</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are alternatives</a:documentation>
                     <value>sequence</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class are to be provided in sequence</a:documentation>
                     <value>sequenceOptional</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided, in sequence, but are optional</a:documentation>
                     <value>sequenceOptionalRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence, but are optional.</a:documentation>
                     <value>sequenceRepeatable</value>
                     <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">members of the class may be provided one or more times, in sequence</a:documentation>
                  </choice>
               </optional>
            </list>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="classes">
      <element name="classes">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(classes) specifies all the classes of which the documented element or class is a member or subclass. [ ]</a:documentation>
         <ref name="classes.content"/>
         <ref name="classes.localattributes"/>
      </element>
   </define>
   <define name="classes.content">
      <zeroOrMore>
         <ref name="memberOf"/>
      </zeroOrMore>
   </define>
   <define name="classes.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="mode"
                    a:defaultValue="replace">
            <a:documentation>specifies the effect of this declaration on its parent module.</a:documentation>
            <choice>
               <value>change</value>
               <a:documentation>this declaration changes the declaration of the same name in the current definition</a:documentation>
               <value>replace</value>
               <a:documentation>this declaration replaces the declaration of the same name in the current definition</a:documentation>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="code">
      <element name="code">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">contains literal code from some formal language such as a programming language. []</a:documentation>
         <ref name="code.content"/>
         <ref name="code.localattributes"/>
      </element>
   </define>
   <define name="code.content">
      <text/>
   </define>
   <define name="code.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="lang">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(formal language) a name identifying the formal language in which the code is expressed.</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="constraint">
      <element name="constraint">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(constraint rules) the formal rules of a constraint []</a:documentation>
         <ref name="constraint.content"/>
         <ref name="constraint.localattributes"/>
      </element>
   </define>
   <define name="constraint.content">
      <zeroOrMore>
         <choice>
            <text/>
            <ref name="anyElement_constraint_5"/>
         </choice>
      </zeroOrMore>
   </define>
   <define name="constraint.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="constraintDecl">
      <element name="constraintDecl">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(constraint declaration) contains declarations pertaining to formal constraints expressed elsewhere in <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;constraintSpec&gt;</code> elements []</a:documentation>
         <ref name="constraintDecl.content"/>
         <ref name="constraintDecl.localattributes"/>
      </element>
   </define>
   <define name="constraintDecl.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identEquiv"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="anyElement_constraintDecl_4"/>
         </zeroOrMore>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintDecl-one-constraintDecl-per-scheme-constraint-rule-77">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="/*[ count( //tei:constraintDecl ) gt 1 ]">
            <sch:let name="schemes"
                     value="//tei:constraintDecl[ not(ancestor::*[local-name(.) eq 'egXML'] ) ]/@scheme"/>
            <sch:let name="disctinct_schemes" value="distinct-values( $schemes )"/>
            <sch:assert test="count( $schemes ) eq count( $disctinct_schemes )">
          Each &lt;constraintDecl&gt; element should have a @scheme attribute that is distinct from that of all the other &lt;constraintDecl&gt;s.
        </sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="constraintDecl.localattributes">
      <ref name="att.global.attributes"/>
      <attribute name="scheme">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies the name of the language to which the declarations herein apply
Suggested values include: 1] schematron (ISO Schematron)</a:documentation>
         <choice>
            <value>schematron</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(ISO Schematron) </a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </choice>
      </attribute>
      <optional>
         <attribute name="queryBinding">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(query language binding) specifies the query language binding for rule-based schema expressions in <code xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;constraintSpec&gt;</code> elements that have a matching <code xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0">@scheme</code> attribute
Suggested values include: 1] exslt; 2] stx; 3] xslt; 4] xslt2; 5] xslt3; 6] xpath; 7] xpath2; 8] xpath3; 9] xpath31; 10] xquery; 11] xquery3; 12] xquery31</a:documentation>
            <choice>
               <value>exslt</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>stx</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xslt</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xslt2</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xslt3</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xpath</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xpath2</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xpath3</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xpath31</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xquery</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xquery3</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <value>xquery31</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               <data type="token">
                  <param name="pattern">[^\p{C}\p{Z}]+</param>
               </data>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="constraintSpec">
      <element name="constraintSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(constraint on schema) contains a formal constraint, typically expressed in a rule-based schema language, to which a construct must conform in order to be considered valid []</a:documentation>
         <ref name="constraintSpec.content"/>
         <ref name="constraintSpec.localattributes"/>
      </element>
   </define>
   <define name="constraintSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identSynonyms"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <ref name="constraint"/>
         </optional>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintSpec-empty-based-on-mode-constraint-rule-79">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec[ @mode eq 'delete']">
            <sch:report test="child::*">This constraintSpec element has a mode= of "delete" even though it has child elements. Change the mode= to "add", "change", or "replace", or remove the child elements.</sch:report>
         </sch:rule>
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec[ @mode eq 'change']">
            <sch:assert test="child::*">This constraintSpec element has a mode= of "change", but does not have any child elements. Specify child elements, or change the mode= to "delete".</sch:assert>
         </sch:rule>
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec[ @mode = ('add','replace') ]">
            <sch:assert test="child::tei:constraint">This constraintSpec element has a mode= of "<sch:value-of select="@mode"/>", but does not have a child 'constraint' element. Use a child 'constraint' element or change the mode= to "delete" or "change".</sch:assert>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintSpec-sch_no_more-constraint-rule-82">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec">
            <sch:report test="tei:constraint/sch1x:* and @scheme = ('isoschematron','schematron')">Rules
        in the Schematron 1.* language must be inside a constraintSpec
        with a value other than 'schematron' or 'isoschematron' on the
        scheme attribute</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintSpec-isosch-constraint-rule-83">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec[ @mode = ('add','replace') or not( @mode ) ]">
            <sch:report test="tei:constraint/sch:* and not( @scheme eq 'schematron')">Rules
          in the ISO Schematron language must be inside a constraintSpec
          with the value 'schematron' on the scheme attribute</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintSpec-context-required-constraint-rule-84">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="(tei:constraintSpec|tei:constraintDecl)[ @scheme eq 'schematron'][ .//sch:assert | .//sch:report ]">
            <sch:let name="assertsHaveContext"
                     value="for $a in .//sch:assert return exists( $a/ancestor::sch:rule/@context )"/>
            <sch:let name="reportsHaveContext"
                     value="for $r in .//sch:report return exists( $r/ancestor::sch:rule/@context )"/>
            <sch:report test="( $assertsHaveContext, $reportsHaveContext ) = false()">An &lt;sch:assert&gt; or &lt;sch:report&gt;
          element must be a descendant of an &lt;sch:rule&gt; that has a @context; one or more inside this
          <sch:value-of select="local-name(.)"/> are not.</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintSpec-unique-constraintSpec-ident-constraint-rule-85">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec[ @mode eq 'add' or not( @mode ) ]">
            <sch:let name="myIdent" value="normalize-space(@ident)"/>
            <sch:report test="preceding::tei:constraintSpec[ normalize-space(@ident) eq $myIdent ]">
        The @ident of 'constraintSpec' should be unique; this one (<sch:value-of select="$myIdent"/>) is the same as that of a previous 'constraintSpec'.
        </sch:report>
         </sch:rule>
      </pattern>
   </define>
   <define name="constraintSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <ref name="att.typed.attribute.subtype"/>
      <optional>
         <attribute name="type">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">characterizes the <code xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;constraintSpec&gt;</code> element in some sense; used to indicate when a <code xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;constraintSpec&gt;</code> warns about a deprecated construct.
Suggested values include: 1] deprecationWarning</a:documentation>
            <choice>
               <value>deprecationWarning</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">Indicates that this constraint specification warns that some other construct in the schema is deprecated.</a:documentation>
               <data type="token">
                  <param name="pattern">[^\p{C}\p{Z}]+</param>
               </data>
            </choice>
         </attribute>
      </optional>
      <optional>
         <attribute name="scheme">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies the name of the language in which the constraints are defined
Suggested values include: 1] schematron (ISO Schematron)</a:documentation>
            <choice>
               <value>schematron</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(ISO Schematron) </a:documentation>
               <data type="token">
                  <param name="pattern">[^\p{C}\p{Z}]+</param>
               </data>
            </choice>
         </attribute>
      </optional>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="constraintSpec-scheme-usage_based_on_mode-constraint-rule-88">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:constraintSpec[ @mode = ('add','replace')  or  not( @mode ) ]">
            <sch:assert test="@scheme">The @scheme attribute of &lt;constraintSpec&gt; is required when the @mode is <sch:value-of select="if (@mode) then concat('&#34;',@mode,'&#34;') else 'not specified'"/> (here on "<sch:value-of select="@ident"/>")</sch:assert>
         </sch:rule>
      </pattern>
      <empty/>
   </define>
   <define name="content">
      <element name="content">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(content model) contains a declaration of the intended content model for the element (or other construct) being specified. []</a:documentation>
         <ref name="content.content"/>
         <ref name="content.localattributes"/>
      </element>
   </define>
   <define name="content.content">
      <choice>
         <ref name="valList"/>
         <ref name="model.contentPart"/>
         <ref name="anyElement_content_3"/>
      </choice>
   </define>
   <define name="content.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="autoPrefix"
                    a:defaultValue="true">
            <a:documentation>controls whether or not pattern names generated in the corresponding RELAX NG schema source are automatically prefixed to avoid potential nameclashes.</a:documentation>
            <choice>
               <value>true</value>
               <a:documentation>Each name referenced in e.g. an <code xmlns="http://www.w3.org/1999/xhtml"
                        xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;rng:ref&gt;</code> element within a content model is automatically prefixed by the value of the <code xmlns="http://www.w3.org/1999/xhtml"
                        xmlns:rng="http://relaxng.org/ns/structure/1.0">@prefix</code> attribute on the current <code xmlns="http://www.w3.org/1999/xhtml"
                        xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;schemaSpec&gt;</code>
               </a:documentation>
               <value>false</value>
               <a:documentation>No prefixes are added: any prefix required by the value of the <code xmlns="http://www.w3.org/1999/xhtml"
                        xmlns:rng="http://relaxng.org/ns/structure/1.0">@prefix</code> attribute on the current <code xmlns="http://www.w3.org/1999/xhtml"
                        xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;schemaSpec&gt;</code> must therefore be supplied explicitly, as appropriate.</a:documentation>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="dataFacet">
      <element name="dataFacet">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">Restricts the value of the strings used to represent values of a datatype, according to <a xmlns="http://www.w3.org/1999/xhtml"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               href="#XSD2">XML Schema Part 2: Datatypes Second Edition</a>. []</a:documentation>
         <ref name="dataFacet.content"/>
         <ref name="dataFacet.localattributes"/>
      </element>
   </define>
   <define name="dataFacet.content">
      <empty/>
   </define>
   <define name="dataFacet.localattributes">
      <ref name="att.global.attributes"/>
      <attribute name="name">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the name of the facet.</a:documentation>
         <choice>
            <value>length</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>minLength</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>maxLength</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>pattern</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>enumeration</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>whiteSpace</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>maxInclusive</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>minInclusive</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>maxExclusive</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>minExclusive</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>totalDigits</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
            <value>fractionDigits</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
         </choice>
      </attribute>
      <attribute name="value">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the facet value.</a:documentation>
         <data type="string"/>
      </attribute>
      <empty/>
   </define>
   <define name="dataRef">
      <element name="dataRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">identifies the datatype of an attribute value, either by referencing an item in an externally defined datatype library, or by pointing to a TEI-defined data specification []</a:documentation>
         <ref name="dataRef.content"/>
         <ref name="dataRef.localattributes"/>
      </element>
   </define>
   <define name="dataRef.content">
      <zeroOrMore>
         <ref name="dataFacet"/>
      </zeroOrMore>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="dataRef-restrictDataFacet-constraint-rule-93">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:dataRef[tei:dataFacet]">
            <sch:assert test="@name" role="nonfatal">Data facets can only be specified for references to datatypes specified by
          XML Schema Part 2: Datatypes Second Edition — that is, for there to be a 'dataFacet' child there must be a @name attribute.</sch:assert>
            <sch:report test="@restriction" role="nonfatal">Data facets and restrictions cannot both be expressed on the same data reference — that is, the @restriction attribute cannot be used when a 'dataFacet' element is present.</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="dataRef-restrictAttResctrictionName-constraint-rule-94">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:dataRef[@restriction]">
            <sch:assert test="@name" role="nonfatal">Restrictions can only be specified for references to datatypes specified by
          XML Schema Part 2: Datatypes Second Edition — that is, for there to be a @restriction attribute there must be a @name attribute, too.</sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="dataRef.localattributes">
      <ref name="att.global.attributes"/>
      <choice>
         <optional>
            <attribute name="key">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the identifier used for this datatype specification</a:documentation>
               <data type="NCName"/>
            </attribute>
         </optional>
         <optional>
            <attribute name="name">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the name of a datatype in the list provided by <a xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0"
                     href="#XSD2">XML Schema Part 2: Datatypes Second Edition</a>
               </a:documentation>
               <data type="NCName"/>
            </attribute>
         </optional>
         <optional>
            <attribute name="ref">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a pointer to a datatype defined in some datatype library</a:documentation>
               <data type="anyURI">
                  <param name="pattern">\S+</param>
               </data>
            </attribute>
         </optional>
      </choice>
      <optional>
         <attribute name="restriction">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a string representing a regular expression providing additional constraints on the strings used to represent values of this datatype</a:documentation>
            <data type="token"/>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="dataSpec">
      <element name="dataSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(datatype specification) documents a datatype. [ ]</a:documentation>
         <ref name="dataSpec.content"/>
         <ref name="dataSpec.localattributes"/>
      </element>
   </define>
   <define name="dataSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identSynonyms"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <choice>
               <ref name="content"/>
               <ref name="valList"/>
            </choice>
         </optional>
         <zeroOrMore>
            <ref name="constraintSpec"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="exemplum"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="remarks"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="listRef"/>
         </zeroOrMore>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="dataSpec-no_elements_in_data_content-constraint-rule-67">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   role="warn"
                   context="tei:dataSpec/tei:content">
            <sch:report test=".//tei:anyElement | .//tei:classRef | .//tei:elementRef">
          A datatype specification should not refer to an element or a class.
        </sch:report>
         </sch:rule>
      </pattern>
   </define>
   <define name="dataSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <empty/>
   </define>
   <define name="datatype">
      <element name="datatype">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(datatype) specifies the declared value for an attribute, by referring to any datatype defined by the chosen schema language. [ ]</a:documentation>
         <ref name="datatype.content"/>
         <ref name="datatype.localattributes"/>
      </element>
   </define>
   <define name="datatype.content">
      <choice>
         <ref name="dataRef"/>
         <ref name="anyElement_datatype_6"/>
      </choice>
   </define>
   <define name="datatype.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="minOccurs"
                    a:defaultValue="1">
            <a:documentation>(minimum number of occurrences) indicates the minimum number of times this datatype may occur in an instance of the attribute being defined.</a:documentation>
            <data type="nonNegativeInteger"/>
         </attribute>
      </optional>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="maxOccurs"
                    a:defaultValue="1">
            <a:documentation>(maximum number of occurrences) indicates the maximum number of times this datatype may occur in an instance of the attribute being defined.</a:documentation>
            <choice>
               <data type="nonNegativeInteger"/>
               <choice>
                  <value>unbounded</value>
                  <a:documentation/>
               </choice>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="defaultVal">
      <element name="defaultVal">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(default value) specifies the default declared value for an attribute. []</a:documentation>
         <ref name="defaultVal.content"/>
         <ref name="defaultVal.localattributes"/>
      </element>
   </define>
   <define name="defaultVal.content">
      <text/>
   </define>
   <define name="defaultVal.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.combinable.attributes"/>
      <empty/>
   </define>
   <define name="eg">
      <element name="eg">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(example) contains any kind of illustrative example. [ ]</a:documentation>
         <ref name="eg.content"/>
         <ref name="eg.localattributes"/>
      </element>
   </define>
   <define name="eg.content">
      <ref name="macro.phraseSeq"/>
   </define>
   <define name="eg.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="egXML">
      <element name="egXML" ns="http://www.tei-c.org/ns/Examples">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(example of XML) a single XML fragment demonstrating the use of some XML, such as elements, attributes, or processing instructions, etc., in which the <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;egXML&gt;</code> element functions as the root element. []</a:documentation>
         <ref name="egXML.content"/>
         <ref name="egXML.localattributes"/>
      </element>
   </define>
   <define name="egXML.content">
      <zeroOrMore>
         <choice>
            <text/>
            <ref name="anyElement_egXML_2"/>
         </choice>
      </zeroOrMore>
   </define>
   <define name="egXML.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="valid"
                    a:defaultValue="true">
            <a:documentation>indicates the intended validity of the example with respect to a schema.</a:documentation>
            <choice>
               <value>true</value>
               <a:documentation>the example is intended to be fully valid, assuming that its root element, or a provided root element, could have been used as a possible root element in the schema concerned.</a:documentation>
               <value>feasible</value>
               <a:documentation>the example could be transformed into a valid document by inserting any number of valid attributes and child elements anywhere within it; or it is valid against a version of the schema concerned in which the provision of character data, list, element, or attribute values has been made optional.</a:documentation>
               <value>false</value>
               <a:documentation>the example is not intended to be valid, and contains deliberate errors.</a:documentation>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="elementRef">
      <element name="elementRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">points to the specification for some element which is to be included in a schema. []</a:documentation>
         <ref name="elementRef.content"/>
         <ref name="elementRef.localattributes"/>
      </element>
   </define>
   <define name="elementRef.content">
      <empty/>
      <sch:pattern xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:rng="http://relaxng.org/ns/structure/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude">
         <sch:rule context="tei:elementRef[ parent::tei:schemaSpec | parent::tei:specGrp ]">
            <sch:report test="@minOccurs | @maxOccurs" role="error">An element reference is not repeatable when part of a schema specification (and thus this &lt;elementRef&gt; should not have @minOccurs or @maxOccurs).</sch:report>
         </sch:rule>
         <sch:rule context="tei:content//tei:elementRef">
            <sch:report test="@source" role="error">An element reference within a content model must refer to a locally defined element specification (and thus this &lt;elementRef&gt; should not have @source).</sch:report>
         </sch:rule>
      </sch:pattern>
   </define>
   <define name="elementRef.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.repeatable.attributes"/>
      <attribute name="key">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the identifier used for the required element within the source indicated.</a:documentation>
         <data type="NCName"/>
      </attribute>
      <empty/>
   </define>
   <define name="elementSpec">
      <element name="elementSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(element specification) documents the structure, content, and purpose of a single element type. [ ]</a:documentation>
         <ref name="elementSpec.content"/>
         <ref name="elementSpec.localattributes"/>
      </element>
   </define>
   <define name="elementSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identSynonyms"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <ref name="classes"/>
         </optional>
         <optional>
            <ref name="content"/>
         </optional>
         <optional>
            <ref name="valList"/>
         </optional>
         <zeroOrMore>
            <ref name="constraintSpec"/>
         </zeroOrMore>
         <optional>
            <ref name="attList"/>
         </optional>
         <zeroOrMore>
            <choice>
               <ref name="model"/>
               <ref name="modelGrp"/>
               <ref name="modelSequence"/>
            </choice>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="exemplum"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="remarks"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="listRef"/>
         </zeroOrMore>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="elementSpec-child-constraint-based-on-mode-constraint-rule-65">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:elementSpec[ @mode eq 'delete' ]">
            <sch:report test="child::*">This elementSpec element has a mode= of "delete" even though it has child elements. Change the mode= to "add", "change", or "replace", or remove the child elements.</sch:report>
         </sch:rule>
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:elementSpec[ @mode = ('add','change','replace') ]">
            <sch:assert test="child::* | (@* except (@mode, @ident))">This elementSpec element has a mode= of "<sch:value-of select="@mode"/>", but does not have any child elements or schema-changing attributes. Specify child elements, use validUntil=, predeclare=, ns=, or prefix=, or change the mode= to "delete".</sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="elementSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <ref name="att.namespaceable.attributes"/>
      <optional>
         <attribute name="prefix">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies a default prefix which will be prepended to all patterns relating to the element, unless otherwise stated.</a:documentation>
            <optional>
               <data type="NCName"/>
            </optional>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="empty">
      <element name="empty">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates the presence of an empty node within a content model. []</a:documentation>
         <ref name="empty.content"/>
         <ref name="empty.localattributes"/>
      </element>
   </define>
   <define name="empty.content">
      <empty/>
   </define>
   <define name="empty.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="equiv">
      <element name="equiv">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(equivalent) specifies a component which is considered equivalent to the parent element, either by co-reference, or by external link. [ ]</a:documentation>
         <ref name="equiv.content"/>
         <ref name="equiv.localattributes"/>
      </element>
   </define>
   <define name="equiv.content">
      <empty/>
   </define>
   <define name="equiv.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.internetMedia.attributes"/>
      <ref name="att.predicate.attributes"/>
      <optional>
         <attribute name="name">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a single word which follows the rules defining a legal XML name (see ), naming the underlying concept of which the parent is a representation.</a:documentation>
            <data type="Name"/>
         </attribute>
      </optional>
      <optional>
         <attribute name="uri">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(uniform resource identifier) references the underlying concept of which the parent is a representation by means of some external identifier.</a:documentation>
            <data type="anyURI">
               <param name="pattern">\S+</param>
            </data>
         </attribute>
      </optional>
      <optional>
         <attribute name="filter">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">references an external script which contains a method to transform instances of this element to canonical TEI.</a:documentation>
            <data type="anyURI">
               <param name="pattern">\S+</param>
            </data>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="exemplum">
      <element name="exemplum">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(exemplum) groups an example demonstrating the use of an element along with optional paragraphs of commentary. []</a:documentation>
         <ref name="exemplum.content"/>
         <ref name="exemplum.localattributes"/>
      </element>
   </define>
   <define name="exemplum.content">
      <group>
         <zeroOrMore>
            <ref name="model.pLike"/>
         </zeroOrMore>
         <choice>
            <ref name="egXML"/>
            <ref name="eg"/>
         </choice>
         <zeroOrMore>
            <ref name="model.pLike"/>
         </zeroOrMore>
      </group>
   </define>
   <define name="exemplum.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.translatable.attributes"/>
      <ref name="att.typed.attributes"/>
      <empty/>
   </define>
   <define name="gi">
      <element name="gi">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(element name) contains the name (generic identifier) of an element. [ ]</a:documentation>
         <ref name="gi.content"/>
         <ref name="gi.localattributes"/>
      </element>
   </define>
   <define name="gi.content">
      <data type="Name"/>
   </define>
   <define name="gi.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="scheme"
                    a:defaultValue="TEI">
            <a:documentation>supplies the name of the scheme in which this name is defined.
Sample values include: 1] TEI; 2] DBK (docbook); 3] XX (unknown); 4] Schematron; 5] HTML</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="ident">
      <element name="ident">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(identifier) contains an identifier or name for an object of some kind in a formal language. <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;ident&gt;</code> is used for tokens such as variable names, class names, type names, function names etc. in formal programming languages. []</a:documentation>
         <ref name="ident.content"/>
         <ref name="ident.localattributes"/>
      </element>
   </define>
   <define name="ident.content">
      <text/>
   </define>
   <define name="ident.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.typed.attributes"/>
      <empty/>
   </define>
   <define name="listRef">
      <element name="listRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(list of references) supplies a list of significant references in the current document or elsewhere. [ ]</a:documentation>
         <ref name="listRef.content"/>
         <ref name="listRef.localattributes"/>
      </element>
   </define>
   <define name="listRef.content">
      <group>
         <zeroOrMore>
            <ref name="desc"/>
         </zeroOrMore>
         <oneOrMore>
            <ref name="model.ptrLike"/>
         </oneOrMore>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="listRef-TagDocsNestinglistRef-constraint-rule-68">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="( tei:classSpec | tei:dataSpec | tei:elementSpec | tei:macroSpec | tei:moduleSpec | tei:schemaSpec | tei:specGrp )/tei:listRef">
            <sch:report test="tei:listRef">In the context of tagset documentation, the listRef element must not self-nest.</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="listRef-TagDocslistRefChildren-constraint-rule-69">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="( tei:classSpec | tei:dataSpec | tei:elementSpec | tei:macroSpec | tei:moduleSpec | tei:schemaSpec | tei:specGrp )/tei:listRef/tei:ptr | ( tei:classSpec | tei:dataSpec | tei:elementSpec | tei:macroSpec | tei:moduleSpec | tei:schemaSpec | tei:specGrp )/tei:listRef/tei:ref">
            <sch:assert test="@target and not( matches( @target,'\s') )">In the context of tagset documentation, each ptr or ref element inside a listRef must have a target attribute with only 1 pointer as its value.</sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="listRef.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.typed.attributes"/>
      <empty/>
   </define>
   <define name="macroRef">
      <element name="macroRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">points to the specification for some pattern which is to be included in a schema. []</a:documentation>
         <ref name="macroRef.content"/>
         <ref name="macroRef.localattributes"/>
      </element>
   </define>
   <define name="macroRef.content">
      <empty/>
   </define>
   <define name="macroRef.localattributes">
      <ref name="att.global.attributes"/>
      <attribute name="key">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the identifier used for the required pattern within the source indicated.</a:documentation>
         <data type="NCName"/>
      </attribute>
      <empty/>
   </define>
   <define name="macroSpec">
      <element name="macroSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(macro specification) documents the function and implementation of a pattern. [ ]</a:documentation>
         <ref name="macroSpec.content"/>
         <ref name="macroSpec.localattributes"/>
      </element>
   </define>
   <define name="macroSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identSynonyms"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <choice>
               <ref name="content"/>
               <ref name="valList"/>
            </choice>
         </optional>
         <zeroOrMore>
            <ref name="constraintSpec"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="exemplum"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="remarks"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="listRef"/>
         </zeroOrMore>
      </group>
   </define>
   <define name="macroSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <empty/>
   </define>
   <define name="memberOf">
      <element name="memberOf">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies class membership of the documented element or class. []</a:documentation>
         <ref name="memberOf.content"/>
         <ref name="memberOf.localattributes"/>
      </element>
   </define>
   <define name="memberOf.content">
      <ref name="macro.xtext"/>
   </define>
   <define name="memberOf.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="key">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies the identifier for a class of which the documented element or class is a member or subclass.</a:documentation>
            <data type="Name"/>
         </attribute>
      </optional>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="mode"
                    a:defaultValue="add">
            <a:documentation>specifies the effect of this declaration on its parent module.</a:documentation>
            <choice>
               <value>add</value>
               <a:documentation>this declaration is added to the current definitions</a:documentation>
               <value>delete</value>
               <a:documentation>this declaration and all of its children are removed from the current setup</a:documentation>
            </choice>
         </attribute>
      </optional>
      <optional>
         <attribute name="max">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies the maximum number of times the element can occur in elements which use this model class in their content model</a:documentation>
            <choice>
               <data type="double"/>
               <data type="token">
                  <param name="pattern">(\-?[\d]+/\-?[\d]+)</param>
               </data>
               <data type="decimal"/>
            </choice>
         </attribute>
      </optional>
      <optional>
         <attribute name="min">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies the minumum number of times the element must occur in elements which use this model class in their content model</a:documentation>
            <choice>
               <data type="double"/>
               <data type="token">
                  <param name="pattern">(\-?[\d]+/\-?[\d]+)</param>
               </data>
               <data type="decimal"/>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="model">
      <element name="model">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">describes the processing intended for a specified element. []</a:documentation>
         <ref name="model.content"/>
         <ref name="model.localattributes"/>
      </element>
   </define>
   <define name="model.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identEquiv"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="param"/>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="outputRendition"/>
         </zeroOrMore>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="model-no_dup_default_models-constraint-rule-70">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:model[ not( parent::tei:modelSequence ) ][ not( @predicate ) ]">
            <sch:let name="output" value="normalize-space( @output )"/>
            <sch:report test="following-sibling::tei:model [ not( @predicate )] [ normalize-space( @output ) eq $output ]">
          There are 2 (or more) 'model' elements in this '<sch:value-of select="local-name(..)"/>'
          that have no predicate, but are targeted to the same output
          ("<sch:value-of select="( $output, parent::modelGrp/@output, 'all')[1]"/>")</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="model-no_dup_models-constraint-rule-71">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:model[ not( parent::tei:modelSequence ) ][ @predicate ]">
            <sch:let name="predicate" value="normalize-space( @predicate )"/>
            <sch:let name="output" value="normalize-space( @output )"/>
            <sch:report test="following-sibling::tei:model [ normalize-space( @predicate ) eq $predicate ] [ normalize-space( @output ) eq $output ]">
          There are 2 (or more) 'model' elements in this
          '<sch:value-of select="local-name(..)"/>' that have
          the same predicate, and are targeted to the same output
          ("<sch:value-of select="( $output, parent::modelGrp/@output, 'all')[1]"/>")</sch:report>
         </sch:rule>
      </pattern>
   </define>
   <define name="model.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.predicate.attributes"/>
      <attribute name="behaviour">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">names the process or function which this processing model uses in order to produce output.
Suggested values include: 1] alternate; 2] anchor; 3] block; 4] body; 5] break; 6] cell; 7] cit; 8] document; 9] figure; 10] glyph; 11] graphic; 12] heading; 13] index; 14] inline; 15] link; 16] list; 17] listItem; 18] metadata; 19] note; 20] omit; 21] paragraph; 22] row; 23] section; 24] table; 25] text; 26] title</a:documentation>
         <choice>
            <value>alternate</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">support display of alternative visualisations, for example by displaying the preferred content, by displaying both in parallel, or by toggling between the two.</a:documentation>
            <value>anchor</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create an identifiable anchor point in the output.</a:documentation>
            <value>block</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a block structure</a:documentation>
            <value>body</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create the body of a document.</a:documentation>
            <value>break</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a line, column, or page break according to the value of type</a:documentation>
            <value>cell</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a table cell</a:documentation>
            <value>cit</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">show the content, with an indication of the source</a:documentation>
            <value>document</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">start a new output document</a:documentation>
            <value>figure</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">make a figure with the title as caption</a:documentation>
            <value>glyph</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">show a character by looking up reference to a chardesc at the given URI</a:documentation>
            <value>graphic</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">if url is present, uses it to display graphic, else display a placeholder image.</a:documentation>
            <value>heading</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">creates a heading.</a:documentation>
            <value>index</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">generate list according to type.</a:documentation>
            <value>inline</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">creates inline element out of content </a:documentation>
            <value>link</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create hyperlink</a:documentation>
            <value>list</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a list. </a:documentation>
            <value>listItem</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a list item.</a:documentation>
            <value>metadata</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create metadata section</a:documentation>
            <value>note</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a note, often out of line, depending on the value of place; could be margin, footnote, endnote, inline</a:documentation>
            <value>omit</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">do nothing, do not process children</a:documentation>
            <value>paragraph</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a paragraph out of content.</a:documentation>
            <value>row</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a table row</a:documentation>
            <value>section</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a new section of the output document</a:documentation>
            <value>table</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create a table</a:documentation>
            <value>text</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create literal text</a:documentation>
            <value>title</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">create document title</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </choice>
      </attribute>
      <optional>
         <attribute name="useSourceRendition">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">whether to obey any rendition attribute that is present.</a:documentation>
            <data type="boolean"/>
         </attribute>
      </optional>
      <optional>
         <attribute name="output">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the intended output.
Sample values include: 1] web; 2] print; 3] plain</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </attribute>
      </optional>
      <optional>
         <attribute name="cssClass">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the name of a CSS class which should be associated with this element</a:documentation>
            <list>
               <oneOrMore>
                  <data type="Name"/>
               </oneOrMore>
            </list>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="modelGrp">
      <element name="modelGrp">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(model group) any grouping of <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;model&gt;</code> or <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;modelSequence&gt;</code> elements with a common output method. []</a:documentation>
         <ref name="modelGrp.content"/>
         <ref name="modelGrp.localattributes"/>
      </element>
   </define>
   <define name="modelGrp.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identEquiv"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <optional>
            <ref name="outputRendition"/>
         </optional>
         <oneOrMore>
            <choice>
               <ref name="modelSequence"/>
               <ref name="model"/>
            </choice>
         </oneOrMore>
      </group>
   </define>
   <define name="modelGrp.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="useSourceRendition">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">whether to obey any rendition attribute which is present.</a:documentation>
            <data type="boolean"/>
         </attribute>
      </optional>
      <optional>
         <attribute name="output">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the intended output method.
Suggested values include: 1] web; 2] print; 3] plaintext</a:documentation>
            <choice>
               <value>web</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the output is intended for presentation in a web format</a:documentation>
               <value>print</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the output is intended for presentation in a print format</a:documentation>
               <value>plaintext</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the output is intended for presentation in a plain text format</a:documentation>
               <data type="token">
                  <param name="pattern">[^\p{C}\p{Z}]+</param>
               </data>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="modelSequence">
      <element name="modelSequence">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">any sequence of model or <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;modelSequence&gt;</code> elements which is to be processed as a single set of actions. []</a:documentation>
         <ref name="modelSequence.content"/>
         <ref name="modelSequence.localattributes"/>
      </element>
   </define>
   <define name="modelSequence.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identEquiv"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <group>
            <ref name="model"/>
            <ref name="model"/>
            <zeroOrMore>
               <ref name="model"/>
            </zeroOrMore>
         </group>
      </group>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="modelSequence-no_outputs_nor_predicates_4_my_kids-constraint-rule-72">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:modelSequence">
            <sch:report test="tei:model[@output]" role="warning">The 'model' children
        of a 'modelSequence' element inherit the @output attribute of the
        parent 'modelSequence', and thus should not have their own</sch:report>
         </sch:rule>
      </pattern>
   </define>
   <define name="modelSequence.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="predicate">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the condition under which this model applies given as an XPath Predicate Expression.</a:documentation>
            <text/>
         </attribute>
      </optional>
      <optional>
         <attribute name="useSourceRendition">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">whether to obey any rendition attribute that is present.</a:documentation>
            <data type="boolean"/>
         </attribute>
      </optional>
      <optional>
         <attribute name="output">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the intended output method.
Suggested values include: 1] web; 2] print; 3] plaintext</a:documentation>
            <choice>
               <value>web</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the output is intended for presentation in a web format</a:documentation>
               <value>print</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the output is intended for presentation in a print format</a:documentation>
               <value>plaintext</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the output is intended for presentation in a plain text format</a:documentation>
               <data type="token">
                  <param name="pattern">[^\p{C}\p{Z}]+</param>
               </data>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="moduleRef">
      <element name="moduleRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(module reference) references a module which is to be incorporated into a schema. []</a:documentation>
         <ref name="moduleRef.content"/>
         <ref name="moduleRef.localattributes"/>
      </element>
   </define>
   <define name="moduleRef.content">
      <optional>
         <ref name="content"/>
      </optional>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="moduleRef-modref-constraint-rule-62">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:moduleRef">
            <sch:report test="* and @key">
          Child elements of <sch:name/> are only allowed when an external module is being loaded
        </sch:report>
         </sch:rule>
      </pattern>
   </define>
   <define name="moduleRef.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="prefix">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies a default prefix which will be prepended to all patterns from the imported module.</a:documentation>
            <optional>
               <data type="NCName"/>
            </optional>
         </attribute>
      </optional>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="moduleRef-prefix-not-same-prefix-constraint-rule-63">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:moduleRef">
            <sch:report test="//*[ not( generate-id(.) eq generate-id( current() ) ) ]/@prefix = @prefix">The prefix attribute
            of <sch:name/> should not match that of any other
            element (it would defeat the purpose)</sch:report>
         </sch:rule>
      </pattern>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="moduleRef-prefix-not-except-and-include-constraint-rule-64">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:moduleRef">
            <sch:report test="@except and @include">It is an error to supply both the @include and @except attributes</sch:report>
         </sch:rule>
      </pattern>
      <choice>
         <optional>
            <attribute name="include">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a list of the elements which are to be copied from the specified module into the schema being defined.</a:documentation>
               <list>
                  <zeroOrMore>
                     <data type="NCName"/>
                  </zeroOrMore>
               </list>
            </attribute>
         </optional>
         <optional>
            <attribute name="except">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies a list of the elements which are not to be copied from the specified module into the schema being defined.</a:documentation>
               <list>
                  <zeroOrMore>
                     <data type="NCName"/>
                  </zeroOrMore>
               </list>
            </attribute>
         </optional>
      </choice>
      <choice>
         <optional>
            <attribute name="key">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">the name of a TEI module</a:documentation>
               <data type="NCName"/>
            </attribute>
         </optional>
         <optional>
            <attribute name="url">
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(uniform resource locator) refers to a non-TEI module of RELAX NG code by external location</a:documentation>
               <data type="anyURI">
                  <param name="pattern">\S+</param>
               </data>
            </attribute>
         </optional>
      </choice>
      <empty/>
   </define>
   <define name="moduleSpec">
      <element name="moduleSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(module specification) documents the structure, content, and purpose of a single module, i.e. a named and externally visible group of declarations. []</a:documentation>
         <ref name="moduleSpec.content"/>
         <ref name="moduleSpec.localattributes"/>
      </element>
   </define>
   <define name="moduleSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identEquiv"/>
               <ref name="idno"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <zeroOrMore>
            <ref name="exemplum"/>
         </zeroOrMore>
         <optional>
            <ref name="remarks"/>
         </optional>
         <zeroOrMore>
            <ref name="listRef"/>
         </zeroOrMore>
      </group>
   </define>
   <define name="moduleSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <ref name="att.typed.attributes"/>
      <empty/>
   </define>
   <define name="outputRendition">
      <element name="outputRendition">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">describes the rendering or appearance intended for all occurrences of an element in a specified context for a specified type of output. []</a:documentation>
         <ref name="outputRendition.content"/>
         <ref name="outputRendition.localattributes"/>
      </element>
   </define>
   <define name="outputRendition.content">
      <text/>
   </define>
   <define name="outputRendition.localattributes">
      <ref name="att.global.attributes"/>
      <optional>
         <attribute name="scope">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">provides a way of defining pseudo-elements, that is, styling rules applicable to specific sub-portions of an element.
Sample values include: 1] first-line; 2] first-letter; 3] before; 4] after</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="param">
      <element name="param">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">provides a parameter for a model behaviour by supplying its name and an XPath expression identifying the location of its content. []</a:documentation>
         <ref name="param.content"/>
         <ref name="param.localattributes"/>
      </element>
   </define>
   <define name="param.content">
      <empty/>
   </define>
   <define name="param.localattributes">
      <ref name="att.global.attributes"/>
      <attribute name="name">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a name for the parameter being supplied.
Suggested values include: 1] alternate; 2] default; 3] height; 4] id; 5] label; 6] level; 7] link; 8] place; 9] type; 10] url; 11] width</a:documentation>
         <choice>
            <value>alternate</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with behaviour alternate, a parameter of this name supplies one of the pair of possible values; for example the regularized form rather than the original form within a <code xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;choice&gt;</code> element.</a:documentation>
            <value>default</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with behaviour alternate, a parameter of this name supplies one of the pair of possible values; for example the original form rather than the regularized form within a <code xmlns="http://www.w3.org/1999/xhtml"
                     xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;choice&gt;</code> element.</a:documentation>
            <value>height</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with behaviour graphic, a parameter of this name supplies a value for the height of the graphic e.g. 300px, 50%.</a:documentation>
            <value>id</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a parameter of this name should supply a unique identifier for the element being processed; as for example with the anchor behaviour</a:documentation>
            <value>label</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a parameter of this name should supply an expression to be used to label something, for example `concat('Page ', @n)` for a page beginning or `@n` for a footnote reference; typically used with the note or break behaviours</a:documentation>
            <value>level</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with the heading behaviour, a parameter of this name supplies a positive integer indicating the hierarchic level of a heading.</a:documentation>
            <value>link</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with the link behaviour, a parameter of this name should supply a URL to be used as the target of a link. </a:documentation>
            <value>place</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with the note behaviour, a parameter of this name should provide a string which describes the intended placement of some text; typical values include margin, footnote, endnote, inline, bottom</a:documentation>
            <value>type</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a parameter of this name can be used to categorize the specified behaviour in any way; for example the kind of break (when used with the break behaviour) or the kind of index to be generated (if used with the index behaviour) etc.</a:documentation>
            <value>url</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with behaviour graphic, a parameter of this name supplies a a URL indicating the graphic intended.</a:documentation>
            <value>width</value>
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">when used with behaviour graphic, a parameter of this name supplies a value for the width of the graphic e.g. 400px, 70%.</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </choice>
      </attribute>
      <attribute name="value">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies an XPath expression which when evaluated provides the value for the parameter</a:documentation>
         <text/>
      </attribute>
      <empty/>
   </define>
   <define name="paramList">
      <element name="paramList">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">list of parameter specifications. [ ]</a:documentation>
         <ref name="paramList.content"/>
         <ref name="paramList.localattributes"/>
      </element>
   </define>
   <define name="paramList.content">
      <zeroOrMore>
         <ref name="paramSpec"/>
      </zeroOrMore>
   </define>
   <define name="paramList.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="paramSpec">
      <element name="paramSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies specification for one parameter of a model behaviour. []</a:documentation>
         <ref name="paramSpec.content"/>
         <ref name="paramSpec.localattributes"/>
      </element>
   </define>
   <define name="paramSpec.content">
      <zeroOrMore>
         <choice>
            <ref name="model.identEquiv"/>
            <ref name="model.descLike"/>
         </choice>
      </zeroOrMore>
   </define>
   <define name="paramSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.identified.attributes"/>
      <empty/>
   </define>
   <define name="remarks">
      <element name="remarks">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(remarks) contains any commentary or discussion about the usage of an element, attribute, class, or entity not otherwise documented within the containing element. [   ]</a:documentation>
         <ref name="remarks.content"/>
         <ref name="remarks.localattributes"/>
      </element>
   </define>
   <define name="remarks.content">
      <oneOrMore>
         <ref name="model.pLike"/>
      </oneOrMore>
   </define>
   <define name="remarks.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.combinable.attributes"/>
      <ref name="att.translatable.attributes"/>
      <optional>
         <attribute name="ident">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">supplies the identifier by which the remarks may be referenced.</a:documentation>
            <data type="Name"/>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="schemaSpec">
      <element name="schemaSpec">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(schema specification) generates a TEI-conformant schema and documentation for it. [  ]</a:documentation>
         <ref name="schemaSpec.content"/>
         <ref name="schemaSpec.localattributes"/>
      </element>
   </define>
   <define name="schemaSpec.content">
      <group>
         <zeroOrMore>
            <choice>
               <ref name="model.identEquiv"/>
               <ref name="model.descLike"/>
            </choice>
         </zeroOrMore>
         <zeroOrMore>
            <choice>
               <ref name="constraintDecl"/>
               <ref name="model.oddRef"/>
               <ref name="model.oddDecl"/>
               <ref name="listRef"/>
            </choice>
         </zeroOrMore>
      </group>
   </define>
   <define name="schemaSpec.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.docStatus.attributes"/>
      <ref name="att.identified.attributes"/>
      <ref name="att.namespaceable.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="start"
                    a:defaultValue="TEI">
            <a:documentation>specifies entry points to the schema, i.e. which patterns may be used as the root of documents conforming to it.</a:documentation>
            <list>
               <oneOrMore>
                  <data type="Name"/>
               </oneOrMore>
            </list>
         </attribute>
      </optional>
      <optional>
         <attribute name="prefix">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies a default prefix which will be prepended to all patterns relating to TEI elements, unless otherwise stated.</a:documentation>
            <optional>
               <data type="NCName"/>
            </optional>
         </attribute>
      </optional>
      <optional>
         <attribute name="targetLang">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(target language) specifies which language to use when creating the objects in a schema if names for elements or attributes are available in more than one language.</a:documentation>
            <choice>
               <data type="language"/>
               <choice>
                  <value/>
                  <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
               </choice>
            </choice>
         </attribute>
      </optional>
      <optional>
         <attribute name="docLang">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(documentation language) specifies which languages to use when creating documentation if the description for an element, attribute, class or macro is available in more than one language.</a:documentation>
            <list>
               <oneOrMore>
                  <choice>
                     <data type="language"/>
                     <choice>
                        <value/>
                        <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"/>
                     </choice>
                  </choice>
               </oneOrMore>
            </list>
         </attribute>
      </optional>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="defaultExceptions"
                    a:defaultValue="http://www.tei-c.org/ns/1.0 teix:egXML">
            <a:documentation>(default namespace exclusions) provides a list of namespaces and/or prefixed element names to be excluded by default from anyName in RELAX NG schemas.</a:documentation>
            <list>
               <oneOrMore>
                  <choice>
                     <data type="anyURI">
                        <param name="pattern">[^/\s]+:\S*</param>
                     </data>
                     <data type="Name">
                        <param name="pattern">.+:.+</param>
                     </data>
                  </choice>
               </oneOrMore>
            </list>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="sequence">
      <element name="sequence">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates that the constructs referenced by its children form a sequence. []</a:documentation>
         <ref name="sequence.content"/>
         <ref name="sequence.localattributes"/>
      </element>
   </define>
   <define name="sequence.content">
      <oneOrMore>
         <ref name="model.contentPart"/>
      </oneOrMore>
      <pattern xmlns="http://purl.oclc.org/dsdl/schematron"
               xmlns:rng="http://relaxng.org/ns/structure/1.0"
               id="sequence-sequencechilden-constraint-rule-75">
         <sch:rule xmlns="http://www.tei-c.org/ns/1.0"
                   xmlns:sch="http://purl.oclc.org/dsdl/schematron"
                   xmlns:xi="http://www.w3.org/2001/XInclude"
                   context="tei:sequence">
            <sch:assert test="count(*) gt 1">The sequence element must have at least two child elements</sch:assert>
         </sch:rule>
      </pattern>
   </define>
   <define name="sequence.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.repeatable.attributes"/>
      <optional>
         <attribute name="preserveOrder">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">if false, indicates that component elements of a sequence may occur in any order.</a:documentation>
            <data type="boolean"/>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="specDesc">
      <element name="specDesc">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(specification description) indicates that a description of the specified element, class, or macro should be included at this point within a document. []</a:documentation>
         <ref name="specDesc.content"/>
         <ref name="specDesc.localattributes"/>
      </element>
   </define>
   <define name="specDesc.content">
      <empty/>
   </define>
   <define name="specDesc.localattributes">
      <ref name="att.global.attributes"/>
      <attribute name="key">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(identifier) supplies the identifier of the documentary element or class for which a description is to be obtained.</a:documentation>
         <data type="Name"/>
      </attribute>
      <optional>
         <attribute name="atts">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(attributes) supplies attribute names for which descriptions should additionally be obtained.</a:documentation>
            <list>
               <zeroOrMore>
                  <data type="Name"/>
               </zeroOrMore>
            </list>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="specGrp">
      <element name="specGrp">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(specification group) contains any convenient grouping of specifications for use within the current module. []</a:documentation>
         <ref name="specGrp.content"/>
         <ref name="specGrp.localattributes"/>
      </element>
   </define>
   <define name="specGrp.content">
      <zeroOrMore>
         <choice>
            <ref name="model.oddDecl"/>
            <ref name="model.oddRef"/>
            <ref name="model.divPart"/>
            <ref name="listRef"/>
         </choice>
      </zeroOrMore>
   </define>
   <define name="specGrp.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="specGrpRef">
      <element name="specGrpRef">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(reference to a specification group) indicates that the declarations contained by the <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;specGrp&gt;</code> referenced should be inserted at this point. []</a:documentation>
         <ref name="specGrpRef.content"/>
         <ref name="specGrpRef.localattributes"/>
      </element>
   </define>
   <define name="specGrpRef.content">
      <empty/>
   </define>
   <define name="specGrpRef.localattributes">
      <ref name="att.global.attributes"/>
      <attribute name="target">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">points at the specification group which logically belongs here.</a:documentation>
         <data type="anyURI">
            <param name="pattern">\S+</param>
         </data>
      </attribute>
      <empty/>
   </define>
   <define name="specList">
      <element name="specList">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(specification list) marks where a list of descriptions is to be inserted into the prose documentation. []</a:documentation>
         <ref name="specList.content"/>
         <ref name="specList.localattributes"/>
      </element>
   </define>
   <define name="specList.content">
      <oneOrMore>
         <ref name="specDesc"/>
      </oneOrMore>
   </define>
   <define name="specList.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="tag">
      <element name="tag">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(tag) contains text of a complete start- or end-tag, possibly including attribute specifications, but excluding the opening and closing markup delimiter characters. []</a:documentation>
         <ref name="tag.content"/>
         <ref name="tag.localattributes"/>
      </element>
   </define>
   <define name="tag.content">
      <text/>
   </define>
   <define name="tag.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.typed.attribute.subtype"/>
      <optional>
         <attribute name="type">
            <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates the type of XML tag intended.</a:documentation>
            <choice>
               <value>start</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a start-tag, with delimiters &lt; and &gt; is intended</a:documentation>
               <value>end</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">an end-tag, with delimiters &lt;/ and &gt; is intended</a:documentation>
               <value>empty</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">an empty tag, with delimiters &lt; and /&gt; is intended</a:documentation>
               <value>pi</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a pi (processing instruction), with delimiters &lt;? and ?&gt; is intended</a:documentation>
               <value>comment</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a comment, with delimiters &lt;!-- and --&gt; is intended</a:documentation>
               <value>ms</value>
               <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">a marked-section, with delimiters &lt;[CDATA[ and ]]&gt; is intended</a:documentation>
            </choice>
         </attribute>
      </optional>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="scheme"
                    a:defaultValue="TEI">
            <a:documentation>supplies the name of the schema in which this tag is defined.
Sample values include: 1] TEI (text encoding initiative); 2] DBK (docbook); 3] XX (unknown); 4] Schematron; 5] HTML</a:documentation>
            <data type="token">
               <param name="pattern">[^\p{C}\p{Z}]+</param>
            </data>
         </attribute>
      </optional>
      <empty/>
   </define>
   <define name="textNode">
      <element name="textNode">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">indicates the presence of a text node in a content model. []</a:documentation>
         <ref name="textNode.content"/>
         <ref name="textNode.localattributes"/>
      </element>
   </define>
   <define name="textNode.content">
      <empty/>
   </define>
   <define name="textNode.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="val">
      <element name="val">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(value) contains a single attribute value. [ ]</a:documentation>
         <ref name="val.content"/>
         <ref name="val.localattributes"/>
      </element>
   </define>
   <define name="val.content">
      <text/>
   </define>
   <define name="val.localattributes">
      <ref name="att.global.attributes"/>
      <empty/>
   </define>
   <define name="valDesc">
      <element name="valDesc">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(value description) specifies any semantic or syntactic constraint on the value that an attribute may take, additional to the information carried by the <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;datatype&gt;</code> element. []</a:documentation>
         <ref name="valDesc.content"/>
         <ref name="valDesc.localattributes"/>
      </element>
   </define>
   <define name="valDesc.content">
      <ref name="macro.phraseSeq.limited"/>
   </define>
   <define name="valDesc.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.combinable.attributes"/>
      <ref name="att.translatable.attributes"/>
      <empty/>
   </define>
   <define name="valItem">
      <element name="valItem">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">documents a single value in a predefined list of values. []</a:documentation>
         <ref name="valItem.content"/>
         <ref name="valItem.localattributes"/>
      </element>
   </define>
   <define name="valItem.content">
      <group>
         <zeroOrMore>
            <ref name="model.identSynonyms"/>
         </zeroOrMore>
         <group>
            <optional>
               <oneOrMore>
                  <ref name="model.descLike"/>
               </oneOrMore>
               <group>
                  <zeroOrMore>
                     <ref name="model.identSynonyms"/>
                     <zeroOrMore>
                        <ref name="model.descLike"/>
                     </zeroOrMore>
                  </zeroOrMore>
               </group>
               <zeroOrMore>
                  <ref name="remarks"/>
               </zeroOrMore>
            </optional>
         </group>
         <optional>
            <ref name="paramList"/>
         </optional>
      </group>
   </define>
   <define name="valItem.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.combinable.attributes"/>
      <attribute name="ident">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">specifies the value concerned.</a:documentation>
         <data type="string"/>
      </attribute>
      <empty/>
   </define>
   <define name="valList">
      <element name="valList">
         <a:documentation xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0">(value list) contains one or more <code xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:rng="http://relaxng.org/ns/structure/1.0">&lt;valItem&gt;</code> elements defining possible values. []</a:documentation>
         <ref name="valList.content"/>
         <ref name="valList.localattributes"/>
      </element>
   </define>
   <define name="valList.content">
      <zeroOrMore>
         <ref name="valItem"/>
      </zeroOrMore>
   </define>
   <define name="valList.localattributes">
      <ref name="att.global.attributes"/>
      <ref name="att.combinable.attributes"/>
      <optional>
         <attribute xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0"
                    name="type"
                    a:defaultValue="open">
            <a:documentation>specifies the extensibility of the list of values specified.</a:documentation>
            <choice>
               <value>closed</value>
               <a:documentation>only the values specified are permitted.</a:documentation>
               <value>semi</value>
               <a:documentation>(semi-open) all the values specified should be supported, but other values are legal and software should have appropriate fallback processing for them.</a:documentation>
               <value>open</value>
               <a:documentation>the values specified are sample values only.</a:documentation>
            </choice>
         </attribute>
      </optional>
      <empty/>
   </define>
   <!--3. macros-->
</grammar>
