The xml-model processing instruction associates a schema with the XML
document that contains the processing instruction. It must be added at the beginning of
the document, just after the XML prologue. The following code snippet contains an
xml-model processing instruction declaration:
<?xml-model href="../schema.sch" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron" phase="ALL" title="Main schema"?>
It is available in the content completion assistant, before XML document root element
and has the following attributes:
- href - schema file location. Mandatory attribute.
- type - content type of schema. Optional attribute with the
following possible values:
- for DTD the recommended value is application/xml-dtd;
- for W3C XML Schema the recommended value is application/xml
or can be left unspecified;
- for RELAX NG the recommended value is application/xml or
can be left unspecified;
- for RELAX NG - compact syntax the recommended value is
application/relax-ng-compact-syntax;
- for Schematron the recommended value is application/xml or
can be left unspecified;
- for NVDL the recommended value is application/xml or can be
left unspecified.
- schematypens - namespace of schema language of referenced schema
with the following possible values:
- for DTD - not specified;
- for W3C XML Schema the recommended value is
http://www.w3.org/2001/XMLSchema;
- for RELAX NG the recommended value is
http://relaxng.org/ns/structure/1.0;
- for RELAX NG - not specified;
- for Schematron the recommended value is
http://purl.oclc.org/dsdl/schematron;
- for NVDL the recommended value is
http://purl.oclc.org/dsdl/nvdl/ns/structure/1.0.
- phase - phase name of validation function in Schematron schema.
Optional attribute.
- title - title for associated schema. Optional attribute.
Older versions of Oxygen XML used the oxygen processing instruction
with the following attributes:
- RNGSchema - specifies the path to the Relax NG schema associated
with the current document;
- type - specifies the type of Relax NG schema. It is used together
with the RNGSchema attribute and can have the value "xml" or "compact";
- NVDLSchema - specifies the path to the NVDL schema associated with
the current document;
- SCHSchema - specifies the path to the SCH schema associated with
the current document.
Note: Documents that use the oxygen processing instruction are compatible
with newer versions of Oxygen XML.