A subjectScheme is a specialized DITA map that defines a collection of controlled values rather than a collection of topics.
Default values in the scheme (specified by <defaultSubject>) apply only if the XML DTD / schema or instance doesn't specify a value in some other way. The precedence of the different methods of setting a value is:
( (title) (optional) then (topicmeta) (optional) then ( (anchor or data or data-about or enumerationdef or hasInstance or hasKind or hasNarrower or hasPart or hasRelated or navref or relatedSubjects or reltable or schemeref or subjectdef or subjectHead or subjectRelTable or topicref or (anchorref or keydef or mapref or topicgroup or topichead or topicset or topicsetref) ) (any number) ) ) |
This element is not contained by any other elements.
- map/map subjectScheme/subjectScheme
<subjectScheme> <!-- Pull in a scheme that defines unix OS values --> <schemeref href="unixOS.ditamap"/> <!-- Define new OS values that are merged with those in the unixOS scheme --> <subjectdef keys="os"> <subjectdef keys="linux"/> <subjectdef keys="mswin"/> <subjectdef keys="zos"/> </subjectdef> <!-- Define application values --> <subjectdef keys="app" navtitle="Applications"> <subjectdef keys="apacheserv" href="subject/apache.dita"/> <subjectdef keys="mysql" href="subject/sql.dita"/> </subjectdef> <!-- Define an enumeration of the platform attribute, equal to each value in the OS subject. This makes the following values valid for the platform attribute: linux, mswin, zos --> <enumerationdef> <attributedef name="platform"/> <subjectdef keyref="os"/> </enumerationdef> <!-- Define an enumeration of the otherprops attribute, equal to each value in the application subjects. This makes the following values valid for the otherprops attribute: apacheserv, mysql --> <enumerationdef> <attributedef name="otherprops"/> <subjectdef keyref="app"/> </enumerationdef> </subjectScheme>
In the following sample, there are subcategories within the general "os" category.
<subjectScheme> <subjectdef keys="os" navtitle="Operating system"> <subjectdef keys="linux" navtitle="Linux"> <subjectdef keys="redhat" navtitle="RedHat Linux"/> <subjectdef keys="suse" navtitle="SuSE Linux"/> </subjectdef> <subjectdef keys="mswin" navtitle="Windows"/> <subjectdef keys="zos" navtitle="z/OS"/> </subjectdef> <enumerationdef> <attributedef name="platform"/> <subjectdef keyref="os"/> </enumerationdef> </subjectScheme>
The following values are valid on the platform attribute: linux, redhat, suse, mswin, zos. If any other values are encountered, processors validating against the scheme should give a warning. As a result, the values could be used in this way:
<p platform="linux">You must set up a cron job to ...</p> <p platform="redhat">To set up the cron job, ...</p>
Processors should be aware of hierarchies of attributes defined in subject scheme maps, and process them differently than they might if the attributes were not defined in a hierarchy. Using the values "linux" and "redhat" from the scheme above, where the subject "linux" is a container for the subject "redhat", filtering and flagging operate as follows:
Allows an ID to be specified for the map. Note that maps do not require IDs (unlike topics), and the map ID is not included in references to elements within a map. |
||||
This attribute is used to reference an ID on a map that can be reused. See 3.4.2.4 The conref attribute for examples and details about the syntax. |
||||
The conrefend attribute is used when reusing a range of elements through conref. The syntax is the same as for the conref attribute; see 3.4.2.6 The conrefend attribute for examples. |
||||
This attribute enables users to push content into a new location. See 3.4.2.5 The conaction attribute for examples and details about the syntax. |
(mark | pushafter | pushbefore | pushreplace | -dita-use-conref-target) |
|||
Allows conref to operate using a key instead of a URI. See 3.4.2.7 The conkeyref attribute for more details about the syntax and behaviors. |
||||
Identifies a location within another map file where this map will be anchored at runtime. Resolution of the map is deferred until the final step in the delivery of any rendered content. For example, anchorref="map1.ditamap/a1" causes this map to be pulled into the location of the anchor point "a1" inside map1.ditamap when map1.ditamap is rendered for delivery. |
||||
Designates the version of the architecture that is in use. The default value will increase with each release of DITA. |
||||
Indicates the specialized domains that are included in the DTD or Schema. This value will differ depending on what domains are included in the current DTD or Schema. |
Varies based on the DTD or Schema; a sample value is "(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic indexing-d)" |
|||
Collection types describe how links relate to each other. The processing default is "unordered", although no default is specified in the DTD or Schema. Indicates that the order of the child topics is not significant. Indicates that the order of the child topics is significant; output processors will typically link between them in order. Indicates that one of the children should be selected. Represents a tight grouping in which each of the referenced topics not only relates to the current topic but also relate to each other. Usage of the collection-type attribute on <reltable> and <relcolspec> is currently undefined and reserved for future use. |
(unordered | sequence | choice | family | -dita-use-conref-target) |
|||
Describes the processing role of the referenced topic. The default for this attribute on this element is "resource-only". Normal topic that is a readable part of the information. The topic is used as a resource for processing purposes, but is not a readable unit of information on its own. This topic should not be included in a rendered table of contents, and the topic should not be rendered on its own. |
||||
Describes the target of a reference. See 3.4.2.8 The type attribute for detailed information on supported values and processing implications. |
||||
The scope attribute identifies the closeness of the relationship between the current document and the target resource. See 3.4.2.10 The scope attribute for more information on values. |
||||
If locktitle is set to "yes", the <navtitle> element or @navtitle attribute is used if it is present. Otherwise, the navtitle is ignored and the navigation title is retrieved from the referenced file. The @navtitle attribute is deprecated in favor of the <navtitle> element. When both a <navtitle> element and a navtitle attribute are specified, the <navtitle> element should be used. The navtitle in the map is used. The navtitle or title of the topic is used. This is the processing default. |
||||
The format attribute identifies the format of the resource being referenced. See 3.4.2.9 The format attribute for details on supported values. |
||||
Defines some specific linking characteristics of a topic's current location in the map. A topic can only be linked to and cannot link to other topics. A topic cannot be linked to but can link to other topics. A topic can be linked to and can link to other topics. Use this to override the linking value of a parent topic. |
(targetonly | sourceonly | normal | none | -dita-use-conref-target) |
|||
Specifies whether a topic appears in the table of contents (toc); on this element the default is no. This value defaults to no for elements such as reltable, which typically cannot appear in the toc, and for elements such as glossref that generally are not desired in the toc. |
(yes | no | -dita-use-conref-target) |
|||
Specifies whether the topic should be included in a print-specific rendition, such as PDF. The processing default is "yes". Include the topic in the print-oriented file. Do not include the topic in a print-oriented file. Only include the topic when rendering the DITA content in a print-oriented context; the topic should not be included in other contexts, such as when rendering as HTML. |
||||
When a set of topics is transformed using a map, the chunk attribute allows multi-topic documents to be broken into smaller files and multiple individual topics to be combined into larger combined documents. For a detailed description of the chunk attribute and its usage, see 2.1.3.7 Chunking in the DITA Architectural Specification. |
||||
select-atts attribute group (props, base, platform, product, audience, otherprops, importance, rev, status) |
A set of related attributes, described in 3.4.1.5 select-atts attribute group |
|||
localization-atts attribute group (translate, xml:lang, dir) |
A set of related attributes, described in 3.4.1.6 localization-atts attribute group. |
|||
A set of related attributes, described in 3.4.1.2 global-atts attribute group |
||||
Common attributes described in 3.4.1.9 Other common DITA attributes |