<mapresources>

Map resources are objects with a @processing-role set to resource-only, for example, key definitions and subject scheme maps. Such resources do not contribute to the navigation structure, although they might be essential for authoring and processing.

Specialization hierarchy

The <mapresources> element is specialized from <topicref>. It is defined in the mapgroup-domain module.

Content model

<topicmeta> ?, ( <data> | <topicref> | <ditavalref> | <keydef> | <mapref> | <mapresources> | <topicgroup> | <topichead> )*

Attributes

The following attributes are available on this element: common map attributes (excluding @chunk and @collection-type), link-relationship attributes, universal attributes, @impose-role, @keyref, and @keys.

For this element, the @processing-role attribute has a default value of resource-only.

The following attributes are available on this element: universal attributes and the attributes defined below.

@cascade (common map attributes)

Specifies how metadata attributes cascade within a map. The specification defines the following values:

merge
Indicates that the metadata attributes cascade, and that the values of the metadata attributes are additive. This is the processing default for the @cascade attribute.
nomerge
Indicates that the metadata attributes cascade, but that they are not additive for <topicref> elements that specify a different value for a specific metadata attribute. If the cascading value for an attribute is already merged based on multiple ancestor elements, that merged value continues to cascade until a new value is encountered. That is, setting cascade="nomerge" does not undo merging that took place on ancestor elements.

Processors can also define custom, implementation-specific tokens for this attribute.

See Cascading of metadata attributes in a DITA map for more information about how this attribute interacts with metadata attributes.

@chunk (common map attributes)
Specifies how a processor should render a map or branch of a map. For example, it can be used to specify that individual topic documents should be rendered as a single document, or that a single document with multiple topics should be rendered as multiple documents.
The following values are valid:
combine
Instructs a processor to combine the referenced source documents for rendering purposes. This is intended for cases where a publishing process normally results in a single output artifact for each source XML document.
split
Instructs a processor to split each topic from the referenced source document into its own document for rendering purposes. This is intended for cases where a publishing process normally results in a single output artifact for each source XML document, regardless of how many DITA topics exist within each source document.

Processors can also define custom, implementation-specific tokens for this attribute.

For a detailed description of the @chunk attribute and its usage, see Chunking.

@collection-type (common map attributes)
Specifies how topics or links relate to each other. The processing default is unordered, although no default is specified in the OASIS-provided grammar files. The following values are valid:
unordered
Indicates that the order of the child topics is not significant.
sequence
Indicates that the order of the child topics is significant. Output processors will typically link between them in order.
choice
Indicates that one of the children should be selected.
family
Indicates a tight grouping in which each of the referenced topics not only relates to the current topic but also relate to each other.
@format (link-relationship attributes)
Specifies the format of the resource that is referenced. See The format attribute for detailed information on supported values and processing implications.
@href (link-relationship attributes)
Specifies a reference to a resource. See The href attribute for detailed information on supported values and processing implications.
@impose-role
Specifies whether this element will impose its role on elements in a referenced map. The attribute is ignored if the target of the reference is not a map or branch of a map. The following values are valid:
keeptarget
The role of the current reference is not imposed on the target of the reference. This is the default for the unspecialized <topicref> element and for many convenience elements such as <keydef>.
impose
The role of the current reference is imposed on the target of the reference. For example, if a specialized topic reference <chapter> uses this value and references a map, a topic reference that resolves in place of the <chapter> will be treated as if it were a chapter.
-dita-use-conref-target
See Using the -dita-use-conref-target value for more information.

See The href attribute for detailed information on supported values and processing implications.

@keyref
Specifies a key name that acts as a redirectable reference based on a key definition within a map. See The keyref attribute for information on using this attribute.
@keys
Specifies one or more names for a resource. See Setting key names with the keys attribute for information on using this attribute.
@keyscope (common map attributes)
Specifies that the element marks the boundaries of a key scope.

See The keyscope attribute for information on using this attribute.

@linking (common map attributes)
Specifies linking characteristics of a topic specific to the location of this reference in a map. If the value is not specified locally, the value might cascade from another element in the map (for cascade rules, see Cascading of metadata attributes in a DITA map). The following values are valid:
targetonly
A topic can only be linked to and cannot link to other topics.
sourceonly
A topic cannot be linked to but can link to other topics.
normal
A topic can be linked to and can link to other topics. Use this to override the linking value of a parent topic.
none
A topic cannot be linked to or link to other topics.
-dita-use-conref-target
See Using the -dita-use-conref-target value for more information.
@processing-role (common map attributes)
Specifies whether the referenced resource is processed normally or treated as a resource that is only included in order to resolve references, such as key or content references. The following values are valid:
normal
Indicates that the resource is a readable part of the information set. It is included in navigation and search results. This is the default value for the <topicref> element.
resource-only
Indicates that the resource should be used only for processing purposes. It is not included in navigation or search results, nor is it rendered as a topic. This is the default value for the <keydef> element.
-dita-use-conref-target
See Using the -dita-use-conref-target value for more information.

If no value is specified but the attribute is specified on a containing element within a map or within the related-links section, the value cascades from the closest containing element.

For this element, the @processing-role attribute has a default value of resource-only.
@scope (link-relationship attributes)
Specifies the closeness of the relationship between the current document and the referenced resource. The following values are valid: local, peer, external, and -dita-use-conref-target.

See The scope attribute for detailed information on supported values and processing implications.

Specifies whether the target is available for searching. If the value is not specified locally, the value might cascade from another element in the map (for cascade rules, see Cascading of metadata attributes in a DITA map). The following values are valid: yes, no, and -dita-use-conref-target.
@subjectrefs (common map attributes)
Specifies one or more keys that are each defined by a subject definition in a subject scheme map. Multiple values are separated by white space.
@toc (common map attributes)
Specifies whether a topic appears in the table of contents (TOC) based on the current map context. If the value is not specified locally, the value might cascade from another element in the map (for cascade rules, see Cascading of metadata attributes in a DITA map). The following values are valid:
yes
The topic appears in a generated TOC.
no
The topic does not appear in a generated TOC.
-dita-use-conref-target
See Using the -dita-use-conref-target value for more information.
@type (link-relationship attributes)
Describes the target of a reference. See The type attribute for detailed information on supported values and processing implications.

Examples

This section is non-normative.

This section provides examples of how the <mapresources> element can be used.

Example 1. Specifying resource-only objects in an intuitive location in a book map

The following code sample illustrate how the <mapresources> element can group references to key definitions, subject schemes, and other resources in a bookmap:

<bookmap>
  <booktitle>
    <mainbooktitle>Test bookmap</mainbooktitle>
  </booktitle>
  <mapresources>
    <mapref href="key-definitions.ditamap"/>
    <mapref href="subject-scheme.ditamap" type="subjectscheme"/>
    <topicref href="cover-page.dita outputclass="cover-page"/>
  </mapresources>
  <!-- ... -->
</bookmap>

Note that this example illustrates that <mapresources> can be used to make topics available for resource-only processing. In this scenario, the company uses a processor that uses content contained in the cover-page.dita file to generate a PDF cover page.

Example 2. Specifying resource-only objects in a map

The following code sample shows a map that contains information for a specific model of a controller. This map is referenced in an omnibus publication that contains information for an entire family of controllers.

<map keyscope="model-XNP09">
  <title>Model XNP09</title>
  <mapresources>
    <keydef keys="model-illustration" href="model-XNP09.png" format="png"/>
    <keydef keys="remove-cover" href="remove-cover-XNP09.png" format="png"/>
  </mapresources>
  <topicref href="model-overview.dita/>
  <topicref href="installing.dita"/>
  <topicref href="uninstalling.dita/>
  ...
</map>