<schema xmlns="http://www.w3.org/2001/XMLSchema" xmlns:gml="http://www.opengis.net/gml" xmlns:sch="http://www.ascc.net/xml/schematron" xmlns:xlink="http://www.w3.org/1999/xlink" targetNamespace="http://www.opengis.net/gml" elementFormDefault="qualified" version="3.0.0" finalDefault="" blockDefault="" attributeFormDefault="unqualified">
    <annotation>
        <appinfo source="urn:opengis:specification:gml:schema-xsd:geometryComplexes:v3.0.0">geometryComplexes.xsd</appinfo>
        <documentation>Copyright (c) 2001-2002 OGC, All Rights Reserved.</documentation>
    </annotation>
    <include schemaLocation="geometryAggregates.xsd"/>
    <element name="CompositeCurve" type="gml:CompositeCurveType" substitutionGroup="gml:_Curve" nillable="false" abstract="false"/>
    <complexType name="CompositeCurveType" mixed="false" abstract="false">
        <annotation>
            <documentation>A CompositeCurve is defined by a sequence of (orientable) curves such that the each curve in the sequence terminates at the start point of the subsequent curve in the list.</documentation>
        </annotation>
        <complexContent>
            <extension base="gml:AbstractCurveType">
                <sequence minOccurs="1" maxOccurs="1">
                    <element ref="gml:curveMember" maxOccurs="unbounded" minOccurs="1" nillable="false">
                        <annotation>
                            <documentation>This element references or contains one curve in the composite curve. The curves are contiguous, the collection of curves is ordered.
NOTE: This definition allows for a nested structure, i.e. a CompositeCurve may use, for example, another CompositeCurve as a curve member.</documentation>
                        </annotation>
                    </element>
                </sequence>
            </extension>
        </complexContent>
    </complexType>
    <element name="CompositeSurface" type="gml:CompositeSurfaceType" substitutionGroup="gml:_Surface" nillable="false" abstract="false"/>
    <complexType name="CompositeSurfaceType" mixed="false" abstract="false">
        <annotation>
            <documentation>A CompositeSurface is defined by a set of orientable surfaces. A composite surface is geometry type with all the geometric properties of a (primitive) surface. Essentially, a composite surface is a collection of surfaces that join in pairs on common boundary curves and which, when considered as a whole, form a single surface.</documentation>
        </annotation>
        <complexContent>
            <extension base="gml:AbstractSurfaceType">
                <sequence minOccurs="1" maxOccurs="1">
                    <element ref="gml:surfaceMember" maxOccurs="unbounded" minOccurs="1" nillable="false">
                        <annotation>
                            <documentation>This element references or contains one surface in the composite surface. The surfaces are contiguous.
NOTE: This definition allows for a nested structure, i.e. a CompositeSurface may use, for example, another CompositeSurface as a member.</documentation>
                        </annotation>
                    </element>
                </sequence>
            </extension>
        </complexContent>
    </complexType>
    <element name="CompositeSolid" type="gml:CompositeSolidType" substitutionGroup="gml:_Solid" nillable="false" abstract="false"/>
    <complexType name="CompositeSolidType" mixed="false" abstract="false">
        <annotation>
            <documentation>A composite solid is a geometry type with all the geometric properties of a (primitive) solid. 
				Essentially, a composite solid is a collection of solids that join in pairs on common boundary surfaces and which, when considered as a whole, form a single solid.</documentation>
        </annotation>
        <complexContent>
            <extension base="gml:AbstractSolidType">
                <sequence minOccurs="1" maxOccurs="1">
                    <element ref="gml:solidMember" maxOccurs="unbounded" minOccurs="1" nillable="false">
                        <annotation>
                            <appinfo>
                                <sch:pattern>
                                    <sch:rule context="gml:solidMember">
                                        <sch:extends rule="hrefOrContent"/>
                                    </sch:rule>
                                </sch:pattern>
                            </appinfo>
                            <documentation>This element references or contains one solid in the composite solid. The solids are contiguous.
NOTE: This definition allows for a nested structure, i.e. a CompositeSolid may use, for example, another CompositeSolid as a member.</documentation>
                        </annotation>
                    </element>
                </sequence>
            </extension>
        </complexContent>
    </complexType>
    <element name="GeometricComplex" type="gml:GeometricComplexType" substitutionGroup="gml:_Geometry" nillable="false" abstract="false"/>
    <complexType name="GeometricComplexType" mixed="false" abstract="false">
        <annotation>
            <documentation>A geometric complex.</documentation>
        </annotation>
        <complexContent>
            <extension base="gml:AbstractGeometryType">
                <sequence minOccurs="1" maxOccurs="1">
                    <element name="element" type="gml:GeometricPrimitivePropertyType" maxOccurs="unbounded" minOccurs="1" nillable="false"/>
                </sequence>
            </extension>
        </complexContent>
    </complexType>
    <complexType name="GeometricComplexPropertyType" mixed="false" abstract="false">
        <annotation>
            <documentation>A property that has a geometric complex as its value domain can either be an appropriate geometry element encapsulated in an element of this type or an XLink reference to a remote geometry element (where remote includes geometry elements located elsewhere in the same document). Either the reference or the contained element must be given, but neither both nor none.
NOTE: The allowed geometry elements contained in such a property (or referenced by it) have to be modelled by an XML Schema choice element since the composites inherit both from geometric complex *and* geometric primitive and are already part of the _GeometricPrimitive substitution group.</documentation>
        </annotation>
        <choice minOccurs="0" maxOccurs="1">
            <element ref="gml:GeometricComplex" minOccurs="1" maxOccurs="1" nillable="false"/>
            <element ref="gml:CompositeCurve" minOccurs="1" maxOccurs="1" nillable="false"/>
            <element ref="gml:CompositeSurface" minOccurs="1" maxOccurs="1" nillable="false"/>
            <element ref="gml:CompositeSolid" minOccurs="1" maxOccurs="1" nillable="false"/>
        </choice>
        <attributeGroup ref="gml:AssociationAttributeGroup">
            <annotation>
                <documentation>This attribute group includes the XLink attributes (see xlinks.xsd). XLink is used in GML to reference remote resources (including those elsewhere in the same document). A simple link element can be constructed by including a specific set of XLink attributes. The XML Linking Language (XLink) is currently a Proposed Recommendation of the World Wide Web Consortium. XLink allows elements to be inserted into XML documents so as to create sophisticated links between resources; such links can be used to reference remote properties.
A simple link element can be used to implement pointer functionality, and this functionality has been built into various GML 3 elements by including the gml:AssociationAttributeGroup.</documentation>
            </annotation>
        </attributeGroup>
    </complexType>
</schema>