Example: How metadata elements cascade from one map to another
This section is non-normative.
In this scenario, a metadata element that is located in a map reference cascades to the topics that are referenced in a nested map.
Assume the following references in
test.ditamap:
<map>
<topicref href="a.ditamap" format="ditamap" toc="no"/>
<mapref href="b.ditamap" audience="developer"/>
<mapref href="c.ditamap#branch2" platform="myPlatform"/>
<mapref href="d.ditamap" subjectrefs="puzzles"/>
</map>
- The map a.ditamap is treated as if
toc="no"
is specified on the root<map>
element. This means that the topics that are referenced by a.ditamap do not appear in the navigation generated by test.ditamap, except for branches within the map that explicitly settoc="yes"
. - The map b.ditamap is treated as if
audience="developer"
is set on the root<map>
element. If the@audience
attribute is already set on the root<map>
element within b.ditamap, the value developer is added to any existing values. - The element with
id="branch2"
within the map c.ditamap is treated as ifplatform="myPlatform"
is specified on that element. If the@platform
attribute is already specified on the element withid="branch"
, the valuemyPlatform is added to existing values. - The map d.ditamap is treated as if
subjectrefs="puzzles"
is set on the root<map>
element. If the@subjectrefs
attribute is already set on the root<map>
element within d.ditamap, the value puzzles is added to any existing values.