Elements (XSM)

Elements are the basic building blocks of an XML model.

An XML model is a tree structure of elements where child elements are attached to parent elements. For example:



Generated schema:



In a schema, elements are declared with <element> tags.

There are two broad kinds of elements:

Note: In a model targeted with the XML-Data Reduced language, local elements are first declared separately, like global elements (with the <ElementType> tag and a name attribute), then within their parent element (with the <element> tag and a type attribute).

Extract of an XDR file:



Parent elements are linked to their child elements through group particles (sequence, choice or all), which contain a group of child elements (see the Group type property in Element Properties).

You can derive an XSD element data type to extend or restrict its values (see the Derivation property in Element Properties).