2 <xs:schema targetNamespace="http://www.w3.org/XML/1998/namespace" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xml="http://www.w3.org/XML/1998/namespace" xml:lang="en">
6 See http://www.w3.org/XML/1998/namespace.html and
7 http://www.w3.org/TR/REC-xml for information about this namespace.
12 <xs:documentation>This schema defines attributes and an attribute group
14 schemas wishing to allow xml:base, xml:lang or xml:space attributes
15 on elements they define.
17 To enable this, such a schema must import this schema
18 for the XML namespace, e.g. as follows:
21 <import namespace="http://www.w3.org/XML/1998/namespace"
22 schemaLocation="http://www.w3.org/2001/03/xml.xsd"/>
24 Subsequently, qualified reference to any of the attributes
25 or the group defined below will have the desired effect, e.g.
29 <attributeGroup ref="xml:specialAttrs"/>
31 will define a type which will schema-validate an instance
32 element with any of those attributes</xs:documentation>
36 <xs:documentation>In keeping with the XML Schema WG's standard versioning
37 policy, this schema document will persist at
38 http://www.w3.org/2001/03/xml.xsd.
39 At the date of issue it can also be found at
40 http://www.w3.org/2001/xml.xsd.
41 The schema document at that URI may however change in the future,
42 in order to remain compatible with the latest version of XML Schema
43 itself. In other words, if the XML Schema namespace changes, the version
45 http://www.w3.org/2001/xml.xsd will change
46 accordingly; the version at
47 http://www.w3.org/2001/03/xml.xsd will not change.
51 <xs:attribute name="lang" type="xs:language">
53 <xs:documentation>In due course, we should install the relevant ISO 2- and 3-letter
54 codes as the enumerated possible values . . .</xs:documentation>
58 <xs:attribute name="space" default="preserve">
60 <xs:restriction base="xs:NCName">
61 <xs:enumeration value="default"/>
62 <xs:enumeration value="preserve"/>
67 <xs:attribute name="base" type="xs:anyURI">
69 <xs:documentation>See http://www.w3.org/TR/xmlbase/ for
70 information about this attribute.</xs:documentation>
74 <xs:attributeGroup name="specialAttrs">
75 <xs:attribute ref="xml:base"/>
76 <xs:attribute ref="xml:lang"/>
77 <xs:attribute ref="xml:space"/>