Setting the XML Schema Version
Oxygen XML Developer lets you set the version of the XML Schema you are editing either in
the XML Schema preferences page, or through the versioning attributes.
If you want to use the versioning attributes, set the minVersion and
maxVersion attributes, from the
http://www.w3.org/2007/XMLSchema-versioning namespace, on the schema
root element.
Note
Using the minVersion and maxVersion Attributes to
Set the XML Schema Version
| Versioning Attributes | XML Schema Version |
|---|---|
minVersion = "1.0" maxVerion = "1.1"
|
1.0 |
minVersion = "1.1"
|
1.1 |
minVersion = "1.0" maxVerion = greater than
"1.1"
|
The XML Schema version defined in the XML Schema preferences page |
| Not set in the XML Schema document | The XML Schema version defined in the XML Schema preferences page |
To change the XML Schema version of the current document, use the Change XML Schema version action from the contextual menu. This is available both in the Text mode, and in the Design mode and opens the Change XML Schema version dialog box. The following options are available:
-
XML Schema 1.0 - Inserts the
minVersionandmaxVersionattributes on theschemaelement and gives them the values "1.0" and "1.1" respectively. Also, the namespace declaration (xmlns:vc=http://www.w3.org/2007/XMLSchema-versioning) is inserted automatically if it does not exist. -
XML Schema 1.1 - Inserts the
minVersionattribute on theschemaelement and gives it the value "1.1". Also, removes themaxVersionattribute if it exists and adds the versioning namespace (xmlns:vc=http://www.w3.org/2007/XMLSchema-versioning) if it is not declared. -
Default XML Schema version - Removes the
minVersionandmaxVersionattributes from theschemaelement. The default schema version, defined in the XML Schema preferences page, is used.
Note
Oxygen XML Developer automatically uses the version set through the versioning attributes, or the default version if the versioning attributes are not declared, when proposing content completion elements and validating an XML Schema. Also, the XML instance validation against an XML Schema is aware of the versioning attributes defined in the XML Schema.
When you generate sample XML files from an XML Schema, Oxygen XML Developer takes into
account the minVersion and maxVersion attributes defined in
the XML Schema.