Example of references and models of elements.
X-definition
<xd:def xmlns:xd = "http://www.xdef.org/xdef/4.2" root = "Family"> <Family> <Father xd:script = "optional; ref Person;" /> <Mother xd:script = "required; ref Person;" /> <Son xd:script = "occurs *; ref Person;" /> <Daughter xd:script = "occurs *; ref Person;" /> </Family> <Person Firstname = "string();" Familyname = "string();" BirthDate = "date();" /> </xd:def>
Input data
<Family> <Father Firstname = "John" Familyname = "Smith" BirthDate = "1971-07-13" /> <Mother Firstname = "Jane" Familyname = "Smith" BirthDate = "1972-09-18" /> <Son Firstname = "Peter" Familyname = "Smith" BirthDate = "1997-01-18" /> <Daughter Firstname = "Mary" Familyname = "Smith" BirthDate = "1998-12-11" /> </Family>
You can edit both
X-definition
and/or
Input data