A valid XML document conforms to rules which
are stated in an external schema of some
sort.
A schema specifies:
-
the name of the root element
-
names for all elements used
-
names
and datatypes and (occasionally) default values for their attributes
-
rules about how elements
can nest
-
and a few other things, depending on the
schema language
n.b. A schema does
not specify anything about what elements "mean"
Schemas can be written in:
-
The W3C schema language
-
Relax NG schema language
-
XML DTD Language
|