<alt>

<alt> (替換) 標明一個替換,或是元素或段落之間的一組不同選擇。 [16.8 Alternation]
組件linking — 16 Linking, Segmentation, and Alignment
屬性att.global (@xml:id, @n, @xml:lang, @rend, @rendition, @xml:base, @xml:space) (att.global.linking (@corresp, @synch, @sameAs, @copyOf, @next, @prev, @exclude, @select)) (att.global.analytic (@ana)) (att.global.facs (@facs)) (att.global.change (@change)) att.pointing (@targetLang, @target, @evaluate) att.typed (@type, @subtype)
targets標明替換元素或段落的識別符碼。
狀態 非必備的
資料類型 2–∞ 次可出現: 

<rng:ref name="data.pointer"/>
data.pointer
以空白鍵隔開
Each value specified must be the same as that specified as value for an xml:id attribute for some other element in the current document.
mode說明在此集合中的替換物件是唯一的或通用的。
狀態 推薦的
資料類型

<rng:ref name="data.enumerated"/>
data.enumerated
合法的值是:
excl
(exclusive) 替換物件是唯一的,例如最多只出現一個替換。
incl
(inclusive) 替換物件不是唯一的,例如出現一個或多個替換。
weights若屬性mode的屬性值是excl,則每個weight皆表明相對應替換的可能性。若屬性mode的屬性值是incl,則每個weight皆表明,在至少一個其他替換存在的前提下,相對應替換的可能性
狀態 非必備的
資料類型 2–∞ 次可出現: 

<rng:ref name="data.probability"/>
data.probability
以空白鍵隔開
a whitespace-separated list of probability values in the range from 0 to 1.
屬於
可包含在於
analysis: cl m phr s span w
figures: cell figure table
linking: ab altGrp seg
nets: graph
spoken: u writing
tagdocs: valDesc
textcrit: app lem rdg wit witDetail
verse: metSym rhyme
可包含空白元素
宣告

<rng:element name="alt">
 <rng:ref name="att.global.attributes"/>
 <rng:ref name="att.global.linking.attributes"/>
 <rng:ref name="att.global.analytic.attributes"/>
 <rng:ref name="att.global.facs.attributes"/>
 <rng:ref name="att.global.change.attributes"/>
 <rng:ref name="att.pointing.attributes"/>
 <rng:ref name="att.typed.attributes"/>
 <rng:optional>
  <rng:attribute name="targets">
   <rng:list>
    <rng:ref name="data.pointer"/>
    <rng:ref name="data.pointer"/>
    <rng:zeroOrMore>
     <rng:ref name="data.pointer"/>
    </rng:zeroOrMore>
   </rng:list>
  </rng:attribute>
 </rng:optional>
 <rng:optional>
  <rng:attribute name="mode">
   <rng:choice>
    <rng:value>excl</rng:value>
    <rng:value>incl</rng:value>
   </rng:choice>
  </rng:attribute>
 </rng:optional>
 <rng:optional>
  <rng:attribute name="weights">
   <rng:list>
    <rng:ref name="data.probability"/>
    <rng:ref name="data.probability"/>
    <rng:zeroOrMore>
     <rng:ref name="data.probability"/>
    </rng:zeroOrMore>
   </rng:list>
  </rng:attribute>
 </rng:optional>
 <rng:empty/>
</rng:element>
element alt
{
   att.global.attributes,
   att.global.linking.attributes,
   att.global.analytic.attributes,
   att.global.facs.attributes,
   att.global.change.attributes,
   att.pointing.attributes,
   att.typed.attributes,
   attribute targets { list { data.pointer, data.pointer, data.pointer* } }?,
   attribute mode { "excl" | "incl" }?,
   attribute weights
   {
      list { data.probability, data.probability, data.probability* }
   }?,
   empty
}
Schematron

<s:report test="@target and @targets">You may not supply both
@target and @targets</s:report>
Schematron

<s:report test="not(@target) and not(@targets)">You must
supply either @target or @targets</s:report>
Schematron

<s:assert test="contains(@target,' ')">You must supply at least two
values for @target</s:assert>
例子
<alt mode="excl" target="#we.fun #we.sun" weights="0.5 0.5"/>