Adocument is considered to be well-formed if it meets all the well-formedness constraints defined by XML specification. These constraints are as follows: |
The document contains one or more elements. |
The document consists of exactly one root element (also known as the document element). |
The name of an element’s end tag matches the name defined in the start tag. |
No attribute may appear more than once within an element. |
Attribute values cannot contain a left-angle bracket (<). |
Elements delimited with start and end tags must nest properly within each other.