HTML and CSS Reference
In-Depth Information
To Enter the Code for the Prolog, Root, Annotation, and Documentation Elements
Table 12-11 shows the code to begin a new XML Schema Definition with a prolog, root, annotation, and
documentation elements.
Table 12-11 Code for the Prolog, Root, Annotation, and Documentation Elements
Line
Code
1
<?xml version=”1.0” encoding=”utf-8” standalone=”yes” ?>
2
3
<xs:schema xmlns:xs=”http://www.w3.org/2001/XMLSchema”>
4
5
<xs:annotation>
<xs:documentation>
6
This XSD describes the data structure of Calumet Restaurant Supply
product listing created July 13, 2014 by S.Sims.
7
</xs:documentation>
8
</xs:annotation>
9
10
11
</xs:schema>
Line 1 is a standard XML processing statement. Line 3 is the <schema> root tag and assigns namespace
declaration from the w3.org Web site. Line 5 is the beginning <annotation> tag for documentation. Line 6 is the
<documentation> tag. Line 7 is the description of this file. Lines 8 and 9 close the tags started on lines 5 and 6.
Line 11 is the closing <schema> tag.
The following step enters the code for the prolog, root, annotation, and documentation elements.
1
If necessary, click line 1.
Enter the XML code
shown in Table 12-11
to create the
beginning of the XML
Schema Definition
with the prolog,
root, annotation,
and documentation
elements, as shown in
Figure 12 - 6.
Why is the closing
root tag included?
It is included so you
do not forget to add
it at the end of the
schema, thus causing
an error when the
schema is validated.
prolog
annotation and
documentation
elements
root element
closing root
element
do not press
e n t e r key
Figure 12-6
 
Search WWH ::




Custom Search