Element Declarations

An XML document can contain the following types of elements:

  • Elements that contain only text, which can be characters or numbers
  • Empty elements
  • Elements that contain only child elements
  • Elements that contain simple content, which is text and attributes
  • Elements that contain mixed content, which is text and other elements

XML schema classifies the elements that contain only text as simple type elements. XML schema classifies the remaining four types of elements as complex type elements.

The graphic shows the type of elements that an XML schema document can contain.
Click the Next button to continue.