Scoping Element Contents with Context
-
Multiple definitions for a role, different labels
<elementRule role="description" label="book-content">
<sequence>
<hedgeRef label="document_metadata" />
<ref label="binding" />
</sequence>
</elementRule>
<elementRule role="description" label="article=content">
<sequence>
<ref label="magazine" />
<hedgeRef label="document_metadata" />
</sequence>
</elementRule>
-
Applying multiple definitions
<elementRule role="magazineArticle">
<sequence>
<ref label="article-description" />
<ref label="article-content" />
</sequence>
</elementRule>
<elementRule role="book">
<sequence>
<ref label="book-description" />
<ref label="book-content" />
</sequence>
</elementRule>
-
Results
Both the magazineArticle element and the book element must now have a description element as their first child element, but the content types are different
Previous Page <
TOC
> Next Page