Suppose in paragraph text we want to be able to have embedded dates link to date descriptions.
We can add a 'dateref' element that has date content.
We'll enforce that the date content has to have a corresponding 'description-of-date' element.
The 'dateref' declaration:
<xs:element name="dateref" type="xs:date"> <xs:keyref name="date-pointer" refer="my:date-key"> <xs:selector xpath="."/> <xs:field xpath="."/> </xs:keyref> </xs:element>