About
Each XML document contains one or more elements, the boundaries of which are either delimited by:
- start-tags and end-tags,
- or, for empty elements, by an empty-element tag.
<myElementName></myElementName>
<empty/> <!-- Empty Element -->
The element structure of an XML document may, for validation purposes, be constrained using declarations.
]] + content + ]]Property
Each element has:
- name (full or local)
- a type,
- may have a set of attribute specifications,
- and a content
Name
Full Name
The full name of an element consists of its local_name and its namespace URI.
Example:
<namespace:local-name>
Local Name
Its name without any namespace
Type
The Name in the start- and end-tags gives the element's type. It's sometimes called its “generic identifier” (GI).
<type></type>
<name></name>
<id></id>
<gi></gi>
You can define the schema between element type via element type declaration
Attribute
See XML - Attribute
Content
Empty
Usage: Inline vs Structure