<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright TEI Consortium. 
Dual-licensed under CC-by and BSD2 licences 
See the file COPYING.txt for details
$Date: 2013-01-04 13:39:33 +0000 (Fri, 04 Jan 2013) $
$Id: att.scoping.xml 11320 2013-01-04 13:39:33Z rahtz $
-->
<classSpec xmlns="http://www.tei-c.org/ns/1.0" 
 xmlns:rng="http://relaxng.org/ns/structure/1.0"
module="tei" type="atts" ident="att.scoping">
  <desc>provides attributes for selecting particular elements within a
  document by means of  XPath.</desc>
  <attList>
    <attDef ident="target" usage="opt">
      <equiv/>
      <desc>points at one or several  elements or  sets of elements by
      means of one or more
      data pointers, using the URI syntax.</desc>
      <datatype maxOccurs="unbounded">
        <rng:ref name="data.pointer"/>
      </datatype>
      <exemplum xml:lang="en">
        <egXML xmlns="http://www.tei-c.org/ns/Examples">Elizabeth went
        to <persName xml:id="ESSEX">Essex</persName>
	<certainty target="#ESSEX" locus="name" degree="0.6"/></egXML>
      </exemplum>
      <remarks>
        <p>If more than one identifier is given, the implication is
        that all elements (or nodesets) are intended. The
        <att>match</att> attribute may also be used as a means of
        identifying groups of elements.</p>
      </remarks>
    </attDef>

    <attDef ident="match" usage="opt">
      <equiv/>
      <desc>supplies an arbitrary XPath expression identifying a set
      of nodes, selected within the context identified by the
      <att>target</att> attribute if this is supplied, or within the
      context of the element bearing this attribute if it is not.
</desc>
      <datatype>
        <rng:text  />
      </datatype>

<valDesc>Any XPath expression using the syntax
defined in <ptr target="#XSLT2"/>. </valDesc>


      <exemplum xml:lang="en">
        <egXML xmlns="http://www.tei-c.org/ns/Examples"><gap reason="cancelled">
            <certainty match="parent::tei:gap/@reason" locus="value" cert="low"/>
          </gap>
				</egXML>
      </exemplum>
      <remarks>
        <p>The expression of certainty applies to the nodeset
	identified by the value of the <att>target</att> attribute,
	possibly modified additionally by the value of the
	<att>match</att> attribute. If neither attribute is present,
	the expression of certainty applies to the context of the
	<gi>certainty</gi> element itself, i.e. its parent element.
</p>
<p>Note that the value of the <att>target</att> attribute may include
an XPointer expression including an XPath expression (see
<ptr target="#SATS"/>). </p>
      </remarks>
    </attDef>


  </attList>
</classSpec>
