A document type shell integrates one or more topic type or map type modules, zero or more domain modules, and zero or more constraint modules. A DTD document type shell is organized into sections, where each section contains a specific type of declaration.
DTD document type shells may not directly declare element types or attributes. A DTD document type shell must conform to the following coding requirements.
Each section of the shell is introduced by a comment. Shells should use these comments to identify each section of the shell. Each section should be present in the shell DTD, even if the section contains no declarations, and must occur in the order they are presented here. The ordering is required by the XML rules for entity declaration precedence and also serve to enable automatic shell creation and modification. Shells should have an initial set of comments that describe the shell and indicate the public identifiers, URNs, or absolute URLs by which the shell should be referenced in DOCTYPE declarations.
<!-- ============================================================= --> <!-- DOMAIN ENTITY DECLARATIONS --> <!-- ============================================================= -->
For each element domain included in the shell, this section must declare an external parameter entity for the domain's entity declaration file and immediately reference the entity. The entity name for the domain declaration consists of the domain name plus the dec suffix. In the following example, the entity file for the highlight domain is included in the document type shell:
<!ENTITY % hi-d-dec PUBLIC "-//OASIS//ENTITIES DITA Highlight Domain//EN" "highlightDomain.ent" >%hi-d-dec;
The domain attribute inclusions section includes the entity declaration files for each attribute domain integrated by the document type. This section should use the comment:
<!-- ============================================================= --> <!-- DOMAIN ATTRIBUTE DECLARATIONS --> <!-- ============================================================= -->
For each attribute domain included in the shell, this section must declare an external parameter entity for the domain's entity declaration file and immediately reference the entity. The entity name for the domain declaration consists of the domain name plus the ent suffix. In the following example, the entity file for a new attribute domain is included in the document type shell:
<!ENTITY % newAtt-d-dec PUBLIC "-//My Company//ENTITIES New Attribute Domain//EN" "newAttDomain.ent" >%newAtt-d-dec;
<!-- ============================================================= --> <!-- DOMAIN EXTENSIONS --> <!-- ============================================================= -->
For each element that is extended by one or more domains, the document type shell redefines the entity for the element. The new definition is a disjunctive list of alternatives comprising the literal name of the element followed by the element extension entity from each domain that is providing specializations. In the following example, the entity for the <pre> element is redefined to allow specializations from the programming, software, and user interface domains:
<!ENTITY % pre "pre | %pr-d-pre; | %sw-d-pre; | %ui-d-pre;">
<!ENTITY % pre "%pr-d-pre; | %sw-d-pre; | %ui-d-pre;">
<!ENTITY noBasePre-c-pre "%pr-d-pre; | %sw-d-pre; | %ui-d-pre;"> <!ENTITY noBasePre-c-att "(topic noBasePre-c)" > <!ENTITY % pre “%noBasePre-c-pre ;“>
<!-- ============================================================= --> <!-- DOMAIN ATTRIBUTE EXTENSIONS --> <!-- ============================================================= -->
The entities for extending the props and base attributes have a null value by default:
<!ENTITY % props-attribute-extensions "" > <!ENTITY % base-attribute-extensions "" >
For each attribute domain included by the shell, the shell must redefine the entity that is extended. The new definition is a list of the attribute extension entities for the domains that are providing specializations.
<!ENTITY % props-attribute-extensions "%newAtt-d-attribute; %othernewAtt-d-attribute;"> <!ENTITY % base-attribute-extensions "%newfrombaseAtt-d-attribute; %othernewfrombaseAtt-d-attribute;">
<!-- ============================================================= --> <!-- TOPIC NESTING OVERRIDES --> <!-- ============================================================= -->
For each topic type integrated in the shell, the document type shell may control nesting of subtopics by redefining the topictype-info-types entity. The definition is usually an OR list of topic types that can be nested in the corresponding parent topic type. Use the literal root element name of each topic, not the corresponding element entity, as in the following example:
<!ENTITY % concept-info-types "concept | myTopicType">
<!ENTITY % info-types "concept | myTopicType">
<!-- ============================================================= --> <!-- DOMAINS ATTRIBUTE OVERRIDE --> <!-- ============================================================= -->
The document type shell must redefine the included-domains entity to list the domains for specializations that are included in the document type, as well as any constraint modules, as in the following example:
<!ENTITY included-domains "&hi-d-att; &ut-d-att; &ui-d-att; &pr-d-att; &sw-d-att; &newAtt-d-att; &noBasePre-c-ph; " >
For a domain or structural module, the domains attribute value entity is declared in the domain's .ent file. For constraint modules, the domains attribute value entity is declared in the module's .mod file constraint modules do not use separate .ent files).
<!-- ============================================================= --> <!-- CONTENT CONSTRAINT INTEGRATION --> <!-- ============================================================= -->
<!ENTITY % strictTaskbody-c-def PUBLIC "-//OASIS//ELEMENTS DITA 1.2 Strict Taskbody Constraint//EN" "strictTaskbodyConstraint.mod" >%strictTaskbody-c-def;
<!-- ============================================================= --> <!-- TOPIC ELEMENT INTEGRATION --> <!-- ============================================================= -->
<!-- ============================================================= --> <!-- MAP ELEMENT INTEGRATION --> <!-- ============================================================= -->
For each structural type integrated in the document type, the document type shell must declare and reference an external parameter entity for the structural type module's .mod file. The entity name consists of the name of the structural type plus a -type suffix. For example:
<!ENTITY % topic-type PUBLIC "-//OASIS//ELEMENTS DITA Topic//EN" "topic.mod" >%topic-type;
<!-- ============================================================= --> <!-- DOMAIN ELEMENT INTEGRATION --> <!-- ============================================================= -->
For each element domain used in the document type, the document type shell must declare and reference an external parameter entity for the domain definition module file (.mod). The entity name consists of the domain name plus a -def suffix. For example:
<!ENTITY % hi-d-def PUBLIC "-//OASIS//ELEMENTS DITA Highlight Domain//EN" "highlightDomain.mod" >%hi-d-def;
Return to main page.
DITA v1.2 CD 03
Copyright © OASIS Open 2005, 2010. All Rights Reserved.