<join>

<join> 텍스트를 구성하고 있는 비연소적 요소를 가리킴으로 텍스트의 파편화된 분절을 식별한다. 16.7 Aggregation
모듈 linking — 16 Linking, Segmentation, and Alignment
전체 속성에 부가 att.pointing (@target, @evaluate) att.typed (@type, @subtype)
targets 가상 요소로 결합될 수 있는 요소 또는 단락의 확인소를 명시한다.
상태 수의적
자료 유형 2–∞ 출현 

<rng:ref name="data.pointer"/>
data.pointer
공백문자로 분리됨
two or more pointers (URIs), separated by whitespace
result 이 집합체의 표상으로 이해될 수 있는 요소의 이름을 명시한다.
상태 수의적
자료 유형

<rng:ref name="data.name"/>
data.name
The generic identifier of an element in the current DTD.
scope 결합된 대상이 제시된 전체 요소(그 뿌리를 포함하는 전체 하부수형도) 또는 대상의 자식노드(하부수형도의 가지)의 포함 여부를 제시한다.
상태 권고적
적법한 값은:
root
대상 속성에 의해 지시된 한 뿌리에 대한 하부수형도가 결합되고, 각 하부수형도는 결합에 의해 생성된 실제 요소의 자식 노드가 된다. [기본값]
branches
대상 속성에 의해 지시된 하부수형도의 자식은 실제 요소의 자식이 된다.(즉, 하부수형도의 뿌리는 없어진다)
에 의해 사용된
포함할 수 있다
core: desc gloss
tagdocs: altIdent equiv
선언

<rng:element name="join">
 <rng:ref name="att.global.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="result">
   <rng:ref name="data.name"/>
  </rng:attribute>
 </rng:optional>
 <rng:optional>
  <rng:attribute name="scope" a:defaultValue="root">
   <rng:choice>
    <rng:value>root</rng:value>
    <rng:value>branches</rng:value>
   </rng:choice>
  </rng:attribute>
 </rng:optional>
 <rng:zeroOrMore>
  <rng:ref name="model.glossLike"/>
 </rng:zeroOrMore>
</rng:element>
element join
{
   att.global.attributes,
   att.pointing.attributes,
   att.typed.attributes,
   attribute targets { list { data.pointer, data.pointer, data.pointer* } }?,
   attribute result { data.name }?,
   attribute scope { "root" | "branches" }?,
   model.glossLike*
}
Schematron

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

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

<sch:assert test="contains(@target,' ')">You must supply at least two
values for @target</sch:assert>

The following example is discussed in section 16.7 Aggregation:

<sp>
 <speaker>Hughie</speaker>
 <p>How does it go? <q>
   <l xml:id="frog_x1">da-da-da</l>
   <l xml:id="frog_l2">gets a new frog</l>
   <l>...</l>
  </q>
 </p>
</sp>
<sp>
 <speaker>Louie</speaker>
 <p>
  <q>
   <l xml:id="frog_l1">When the old pond</l>
   <l>...</l>
  </q>
 </p>
</sp>
<sp>
 <speaker>Dewey</speaker>
 <p>
  <q>... <l xml:id="frog_l3">It's a new pond.</l>
  </q>
 </p>
 <join targets="#frog_l1 #frog_l2 #frog_l3" result="lg" scope="root"/>
</sp>

The join element here identifies a linegroup (lg) comprising the three lines indicated by the targets attribute. The value root for the scope attribute indicates that the resulting virtual element contains the three l elements linked to at #frog_l1 #frog_l2 #frog_l3, rather than their character data content.

In this example, the attribute scope is specified with the value of branches to indicate that the virtual list being constructed is to be made by taking the lists indicated by the targets attribute of the join element, discarding the list tags which enclose them, and combining the items contained within the lists into a single virtual list:

<p>Southern dialect (my own variety, at least) has only <list xml:id="LP1">
  <item>
   <s>I done gone</s>
  </item>
  <item>
   <s>I done went</s>
  </item>
 </list> whereas Negro Non-Standard basilect has both these and <list xml:id="LP2">
  <item>
   <s>I done go</s>
  </item>
 </list>.</p>
<p>White Southern dialect also has <list xml:id="LP3">
  <item>
   <s>I've done gone</s>
  </item>
  <item>
   <s>I've done went</s>
  </item>
 </list> which, when they occur in Negro dialect, should probably be considered as borrowings from other varieties of English.</p>
<join
  result="list"
  xml:id="LST1"
  targets="#LP1 #LP2 #LP3"
  scope="branches">

 <desc>Sample sentences in Southern speech</desc>
</join>