##### 2.1.3.1 Module compatibility and the @domains attribute

A given DITA document declares, through the @domains attribute on <map> and <topic> elements, the set of vocabulary and constraint modules on which it depends.

The @domains attribute serves two primary purposes:

- To indicate to DITA processors the specific features that they should or must provide in order to completely process the document.
- To determine the validity of elements that are copied from one DITA document to another. This copying may occur as the result of a content reference (conref) or key reference (keyref), or may occur in the context of an author editing a DITA document.

A processor can examine the value of the @domains attribute and compare the set of modules listed to the set of modules for which it provides direct support. It then can take appropriate action if it does not provide support for a given module, for example, issuing a warning before applying fallback processing.

When copying, it is necessary to determine if the data being copied (the copy source) requires modules that are not required by the document into which the data is to be copied (the copy target). Such a copy operation is always safe if the copy source requires a subset of the modules that are required by the copy target. Such a copy is unsafe if the copy source requires modules that are not required by the copy target.

When a copy operation is unsafe, processors may compare the copy source to the copy target to determine if the copy source satisfies the constraints of the copy target. If the copy source meets the copy target constraints, the copy may be allowed. Processors should issue a warning that the copy was allowed but the constraints are not compatible. If the copy source does not meet the constraints of the copy target, processors may apply generalization until the generalized result either satisfies the copy target constraints or no further generalization can be performed. If the copy operation can be performed following generalization, the processor should issue a warning that the constraints are not compatible and generalization had to be performed in order to complete the copy operation.

Previous Topic: 2.1.3 DITA processing

Next Topic: 2.1.3.2 Navigation behaviors

Parent Topic: 2.1.3 DITA processing

Sibling Topics:

2.1.3.2 Navigation behaviors

2.1.3.3 DITA linking

2.1.3.4 DITA addressing

2.1.3.5 Content inclusion (conref)

2.1.3.6 Conditional processing (profiling)

2.1.3.7 Chunking

2.1.3.8 Printing

2.1.3.9 Translation and localization