<?xml version="1.0" encoding="UTF-8" ?>
<schema targetNamespace="http://www.opengis.net/gml" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:gml="http://www.opengis.net/gml" elementFormDefault="qualified" version="3.0.1" xml:lang="en">
    <annotation>
        <appinfo source="urn:opengis:specification:gml:schema-referenceSystems:v3.0c3" />
        <documentation>
            <name>referenceSystems.xsd</name>
            <version>3.0</version>
            <scope>How to encode reference system definitions. </scope>
            <description>Builds on several other parts of GML 3 to encode the data needed to define reference systems. Primary editor: Arliss Whiteside. Last updated 2003/05/21. </description>
            <copyright>Copyright (c) 2002-2003 Open GIS Consortium, All Rights Reserved.</copyright>
            <conformance>This schema encodes the Reference System (RS_) package of the extended UML Model for OGC Abstract Specification Topic 2: Spatial Referencing by Coordinates. That UML model is adapted from ISO 19111 - Spatial referencing by coordinates, as described in Annex B of Topic 2. The SC_CRS class is also encoded here, to eliminate the (circular) references from coordinateOperations.xsd to coordinateReferenceSystems.xsd. The RS_SpatialReferenceSystemUsingGeographicIdentifier class is not encoded, since it is not applicable to coordinate positions. The CI_Citation class is not directly encoded, since such information can be included as metaDataProperty elements which are optionally allowed. A modified version of the EX_Extent (DataType) class from ISO 19115 is currently encoded here, using GML 3 schema types. (A more extensive version of the EX_Extent package might be XML encoded in the future, probably in a separate extent.xsd schema.) </conformance>
        </documentation>
    </annotation> <!-- ======================================================
       includes and imports
	====================================================== -->
    <include schemaLocation="dictionary.xsd" />
    <include schemaLocation="geometryBasic2d.xsd" />
    <include schemaLocation="temporal.xsd" /> <!-- ======================================================
       elements and types
	====================================================== -->
    <element name="_ReferenceSystem" type="gml:AbstractReferenceSystemType" abstract="true" substitutionGroup="gml:Definition" /> <!-- =================================================== -->
    <complexType name="AbstractReferenceSystemBaseType" abstract="true">
        <annotation>
            <documentation>Basic encoding for reference system objects, simplifying and restricting the DefinitionType as needed. </documentation>
        </annotation>
        <complexContent>
            <restriction base="gml:DefinitionType">
                <sequence>
                    <element ref="gml:metaDataProperty" minOccurs="0" maxOccurs="unbounded" />
                    <element ref="gml:remarks" minOccurs="0">
                        <annotation>
                            <documentation>Comments on or information about this reference system, including source information. </documentation>
                        </annotation>
                    </element>
                    <element ref="gml:srsName" />
                </sequence>
                <attribute ref="gml:id" use="required" />
            </restriction>
        </complexContent>
    </complexType> <!-- =================================================== -->
    <element name="srsName" type="gml:SimpleNameType" substitutionGroup="gml:name">
        <annotation>
            <documentation>The name by which this reference system is identified. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <complexType name="AbstractReferenceSystemType" abstract="true">
        <annotation>
            <documentation>Description of a spatial and/or temporal reference system used by a dataset. </documentation>
        </annotation>
        <complexContent>
            <extension base="gml:AbstractReferenceSystemBaseType">
                <sequence>
                    <element ref="gml:srsID" minOccurs="0" maxOccurs="unbounded" />
                    <element ref="gml:validArea" minOccurs="0" />
                    <element ref="gml:scope" minOccurs="0" />
                </sequence>
            </extension>
        </complexContent>
    </complexType> <!-- =================================================== -->
    <element name="srsID" type="gml:IdentifierType">
        <annotation>
            <documentation>An identification of this reference system. The first srsID, if any, is normally the primary identification code, and any others are aliases. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="referenceSystemRef" type="gml:ReferenceSystemRefType" substitutionGroup="gml:dictionaryEntry" /> <!-- =================================================== -->
    <complexType name="ReferenceSystemRefType">
        <annotation>
            <documentation>Association to a reference system, either referencing or containing the definition of that reference system. </documentation>
        </annotation>
        <complexContent>
            <restriction base="gml:DictionaryEntryType">
                <sequence>
                    <element ref="gml:_ReferenceSystem" minOccurs="0" />
                </sequence>
                <attributeGroup ref="gml:AssociationAttributeGroup" />
            </restriction>
        </complexContent>
    </complexType> <!-- =================================================== -->
    <element name="_CRS" type="gml:AbstractCRSType" abstract="true" substitutionGroup="gml:_ReferenceSystem" /> <!-- =================================================== -->
    <complexType name="AbstractCRSType" abstract="true">
        <annotation>
            <documentation>Abstract coordinate reference system, usually defined by a coordinate system and a datum. This abstract complexType shall not be used, extended, or restricted, in an Application Schema, to define a concrete subtype with a meaning equivalent to a concrete subtype specified in this document. </documentation>
        </annotation>
        <complexContent>
            <extension base="gml:AbstractReferenceSystemType" />
        </complexContent>
    </complexType> <!-- =================================================== -->
    <element name="crsRef" type="gml:CRSRefType" substitutionGroup="gml:referenceSystemRef" /> <!-- =================================================== -->
    <complexType name="CRSRefType">
        <annotation>
            <documentation>Association to a CRS abstract coordinate reference system, either referencing or containing the definition of that CRS. </documentation>
        </annotation>
        <complexContent>
            <restriction base="gml:ReferenceSystemRefType">
                <sequence>
                    <element ref="gml:_CRS" minOccurs="0" />
                </sequence>
                <attributeGroup ref="gml:AssociationAttributeGroup" />
            </restriction>
        </complexContent>
    </complexType> <!-- =================================================== --> <!-- =================================================== -->
    <complexType name="SimpleNameType">
        <annotation>
            <documentation>The primary name of a reference system object. The string in the CodeType contains the object identification name, and the codeSpace attribute is not included. </documentation>
        </annotation>
        <simpleContent>
            <restriction base="gml:CodeType">
                <attribute name="codeSpace" type="anyURI" use="prohibited" />
            </restriction>
        </simpleContent>
    </complexType> <!-- =================================================== -->
    <complexType name="IdentifierType">
        <annotation>
            <documentation>An identification of a CRS object. The first use of the IdentifierType for an object, if any, is normally the primary identification code, and any others are aliases. </documentation>
        </annotation>
        <sequence>
            <element ref="gml:code" />
            <element ref="gml:codeSpace" minOccurs="0" />
            <element ref="gml:version" minOccurs="0" />
            <element ref="gml:remarks" minOccurs="0">
                <annotation>
                    <documentation>Remarks about this code or alias. </documentation>
                </annotation>
            </element>
        </sequence>
    </complexType> <!-- =================================================== -->
    <element name="code" type="string">
        <annotation>
            <documentation>Identifier code or name, often from a controlled list or pattern defined by a code space. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="codeSpace" type="gml:CodeType">
        <annotation>
            <documentation>Identifier of a code space within which one or more codes are defined. This code space is optional but is normally included. This code space is often defined by some authority organization, where one organization may define multiple code spaces. The range and format of each Code Space identifier is defined by that code space authority. Information about that code space authority can be included as metaDataProperty elements which are optionally allowed in all CRS objects. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="version" type="string">
        <annotation>
            <documentation>Identifier of the version of the associated codeSpace or code, as specified by the codeSpace or code authority. This version is included only when the "code" or "codeSpace" uses versions. When appropriate, the version is identified by the effective date, coded using ISO 8601 date format. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="remarks" type="gml:StringOrRefType" substitutionGroup="gml:description">
        <annotation>
            <documentation>Information about this object or code. Contains text or refers to external text.  </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="scope" type="string">
        <annotation>
            <documentation>Description of domain of usage, or limitations of usage, for which this CRS object is valid. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="validArea" type="gml:ExtentType">
        <annotation>
            <documentation>Area or region in which this CRS object is valid. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <complexType name="ExtentType">
        <annotation>
            <documentation>Information about the spatial, vertical, and/or temporal extent of a reference system object. Constraints: At least one of the elements "description", "boundingBox", "boundingPolygon", "verticalExtent", and temporalExtent" must be included, but more that one can be included when appropriate. Furthermore, more than one "boundingBox", "boundingPolygon", "verticalExtent", and/or temporalExtent" element can be included, with more than one meaning the union of the individual domains. </documentation>
        </annotation>
        <sequence>
            <element ref="gml:description" minOccurs="0">
                <annotation>
                    <documentation>Description of spatial and/or temporal extent of this object. </documentation>
                </annotation>
            </element>
            <choice>
                <annotation>
                    <documentation>Geographic domain of this reference system object. </documentation>
                </annotation>
                <element ref="gml:boundingBox" minOccurs="0" maxOccurs="unbounded" />
                <element ref="gml:boundingPolygon" minOccurs="0" maxOccurs="unbounded" />
            </choice>
            <element ref="gml:verticalExtent" minOccurs="0" maxOccurs="unbounded" />
            <element ref="gml:temporalExtent" minOccurs="0" maxOccurs="unbounded" />
        </sequence>
    </complexType> <!-- =================================================== -->
    <element name="boundingBox" type="gml:EnvelopeType">
        <annotation>
            <documentation>Bounding box (or envelope) spatial domain of this object. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="boundingPolygon" type="gml:PolygonType">
        <annotation>
            <documentation>Bounding polygon horizontal spatial domain of this object. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="verticalExtent" type="gml:EnvelopeType">
        <annotation>
            <documentation>Vertical spatial domain of this object. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
    <element name="temporalExtent" type="gml:TimePeriodType">
        <annotation>
            <documentation>Time period domain of this object. </documentation>
        </annotation>
    </element> <!-- =================================================== -->
</schema>
