<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2008 (http://www.altova.com) by Peter Schut (Agriculture Canada) -->
<schema xmlns="http://www.w3.org/2001/XMLSchema" xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:gls="http://www.opengis.net/gls/0.11" targetNamespace="http://www.opengis.net/gls/0.11" elementFormDefault="qualified" attributeFormDefault="unqualified" version="0.11" xml:lang="en">
	<annotation>
		<appinfo>$Id: glsGetData_response.xsd 2008-01-04 $</appinfo>
		<documentation>
			<description>This XML Schema encodes the GLS GetData response.</description>
			<copyright>Copyright (c) 2008 OpenGIS, All Rights Reserved. </copyright>
		</documentation>
	</annotation>
	<!-- ========= includes and imports ================================ -->
	<import namespace="http://www.opengis.net/ows/1.1" schemaLocation="../../ows/1.1.0/owsAll.xsd"/>
	<import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
	<!-- ========= top level element =================================== -->
	<element name="GDAS">
		<annotation>
			<documentation>Geospatial Data Attribute Set</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element ref="gls:Framework"/>
			</sequence>
			<attribute name="service" use="required"/>
			<attribute name="version" use="required"/>
			<attribute ref="xml:lang" use="required">
				<annotation>
					<documentation>RFC 4646 language code of the human-readable text (e.g. "en-CA")</documentation>
				</annotation>
			</attribute>
		</complexType>
		<key name="attributeNameKey">
			<annotation>
				<documentation>The value of the 'Dataset/Attribute/Name' element is referenced by the 'aid' attribute of the 'Rowset/Row/V' element.</documentation>
			</annotation>
			<selector xpath="./gls:Dataset/gls:Attribute"/>
			<field xpath="gls:Name"/>
		</key>
		<keyref name="attributeKeyRef" refer="gls:attributeNameKey">
			<annotation>
				<documentation>The value for the 'aid' attribute  must be a value present in the  'Dataset/Attribute/Name' element.</documentation>
			</annotation>
			<selector xpath="./gls:Rowset/gls:Row/gls:V"/>
			<field xpath="@aid"/>
		</keyref>
	</element>
	<!-- ========= other elements ==================================== -->
	<element name="Abstract" type="string">
		<annotation>
			<documentation>One or more paragraphs of human-readable relevant text suitable for display in a pop-up window.</documentation>
		</annotation>
	</element>
	<element name="Attribute">
		<annotation>
			<documentation>Attribute descriptions.  The order of these is determined by the order of the attributes listed in the request.</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element ref="gls:AttributeName"/>
				<element ref="gls:Title"/>
				<element ref="gls:Abstract">
					<annotation>
						<documentation>One or more paragraphs of human-readable text describing the attribute and suitable for display in a pop-up window.</documentation>
					</annotation>
				</element>
				<element ref="gls:Documentation" minOccurs="0"/>
				<element ref="gls:Values">
					<annotation>
						<documentation>Valid values.</documentation>
					</annotation>
				</element>
			</sequence>
		</complexType>
	</element>
	<element name="AttributeName" type="string">
		<annotation>
			<documentation>Name of the attribute field in the database.</documentation>
		</annotation>
	</element>
	<element name="Count">
		<annotation>
			<documentation>Data consists of the number of some observable elements present in the spatial features</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element ref="gls:UOM"/>
				<element ref="gls:Exceptions" minOccurs="0"/>
			</sequence>
			<attribute name="type" use="required">
				<annotation>
					<documentation>Datatype, as defined by XML schema.</documentation>
				</annotation>
				<simpleType>
					<restriction base="string">
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#integer"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#decimal"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#float"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#double"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="length" type="nonNegativeInteger" use="required">
				<annotation>
					<documentation>Length of the field, in characters.</documentation>
				</annotation>
			</attribute>
		</complexType>
	</element>
	<element name="DataClass">
		<simpleType>
			<restriction base="string">
				<enumeration value="nominal"/>
				<enumeration value="ordinal"/>
				<enumeration value="measure"/>
				<enumeration value="count"/>
			</restriction>
		</simpleType>
	</element>
	<element name="Dataset">
		<complexType>
			<sequence>
				<element ref="gls:DatasetDomain"/>
				<element ref="gls:DatasetName"/>
				<element ref="gls:DatasetVersion"/>
				<element ref="gls:Organization"/>
				<element ref="gls:Title"/>
				<element ref="gls:Abstract"/>
				<element ref="gls:ReleaseDate"/>
				<element ref="gls:Documentation" minOccurs="0"/>
				<element ref="gls:DatasetKey"/>
				<element ref="gls:KeyRelationship"/>
				<element ref="gls:KeyComplete"/>
				<element ref="gls:Attribute" maxOccurs="unbounded"/>
				<element ref="gls:Rowset"/>
			</sequence>
		</complexType>
	</element>
	<element name="DatasetDomain" type="string">
		<annotation>
			<documentation>Domain name of the organization responsible for maintaining the attribute dataset.</documentation>
		</annotation>
	</element>
	<element name="DatasetKey">
		<annotation>
			<documentation>Name of the common key field found in the attribute dataset whose contents match those of the foreign key found in the spatial framework.  These values populate the 'Rowset/Row/K' elements.</documentation>
		</annotation>
		<complexType>
			<simpleContent>
				<extension base="string">
					<attribute name="type" use="required">
						<annotation>
							<documentation>Datatype, as defined by XML schema.</documentation>
						</annotation>
						<simpleType>
							<restriction base="string">
								<enumeration value="http://www.w3.org/TR/xmlschema-2/#string"/>
								<enumeration value="http://www.w3.org/TR/xmlschema-2/#integer"/>
								<enumeration value="http://www.w3.org/TR/xmlschema-2/#decimal"/>
								<enumeration value="http://www.w3.org/TR/xmlschema-2/#float"/>
								<enumeration value="http://www.w3.org/TR/xmlschema-2/#double"/>
							</restriction>
						</simpleType>
					</attribute>
					<attribute name="length" type="nonNegativeInteger" use="required">
						<annotation>
							<documentation>Length of the field, in characters.</documentation>
						</annotation>
					</attribute>
				</extension>
			</simpleContent>
		</complexType>
	</element>
	<element name="DatasetName" type="string">
		<annotation>
			<documentation>Name of the attribute dataset.  Normally the name of the dataset inside the RDBMS.</documentation>
		</annotation>
	</element>
	<element name="DatasetVersion" type="string">
		<annotation>
			<documentation>Version number of the attribute dataset.  The combination of DatasetDomain, DatasetName, and DatasetVersion must uniquely reference one spatial dataset.</documentation>
		</annotation>
	</element>
	<element name="Documentation" type="anyURI">
		<annotation>
			<documentation>URL reference to a web-accessible resource which contains further information describing this object.</documentation>
		</annotation>
	</element>
	<element name="Exceptions">
		<annotation>
			<documentation>Valid exception classes for this attribute.</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element name="Null" maxOccurs="unbounded">
					<annotation>
						<documentation>Valid null values.</documentation>
					</annotation>
					<complexType>
						<sequence>
							<element ref="gls:Identifier">
								<annotation>
									<documentation>Text string representing a null value, found in the V elements of this attribute</documentation>
								</annotation>
							</element>
							<element ref="gls:Title"/>
							<element ref="gls:Abstract"/>
							<element ref="gls:Documentation" minOccurs="0"/>
						</sequence>
					</complexType>
				</element>
			</sequence>
		</complexType>
	</element>
	<element name="Framework">
		<annotation>
			<documentation>Spatial Framework to which the attributes apply.</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element ref="gls:FrameworkDomain"/>
				<element ref="gls:FrameworkName"/>
				<element ref="gls:FrameworkVersion"/>
				<element ref="gls:Organization"/>
				<element ref="gls:Title"/>
				<element ref="gls:Abstract"/>
				<element ref="gls:ReleaseDate"/>
				<element ref="gls:Documentation" minOccurs="0"/>
				<element ref="gls:FrameworkKey"/>
				<element ref="gls:Dataset"/>
			</sequence>
		</complexType>
	</element>
	<element name="FrameworkDomain" type="string">
		<annotation>
			<documentation>Domain name of the organization responsible for maintaining the spatial framework.</documentation>
		</annotation>
	</element>
	<element name="FrameworkKey" type="string">
		<annotation>
			<documentation>Name of the common key field in the spatial framework dataset through which data can be joined.  The values of this key populate the 'Rowset/Row/K' elements in the GetData response.</documentation>
		</annotation>
	</element>
	<element name="FrameworkName" type="string">
		<annotation>
			<documentation>Name of the spatial framework.  Normally the name of the GIS dataset.</documentation>
		</annotation>
	</element>
	<element name="FrameworkVersion" type="string">
		<annotation>
			<documentation>Version number of the spatial framework.  The combination of FrameworkDomain, FrameworkName and FrameworkVersion must uniquely reference one spatial framework.</documentation>
		</annotation>
	</element>
	<element name="K" type="string">
		<annotation>
			<documentation>Spatial Key</documentation>
		</annotation>
	</element>
	<element name="Identifier" type="string"/>
	<element name="KeyComplete" type="boolean">
		<annotation>
			<documentation>Identifies if there is at least one record in the Attribute dataset for every record in the Framework dataset.  “true” indicates that this is the case. “false” indicates that some Keys in the Framework dataset cannot be found in the Attribute dataset.</documentation>
		</annotation>
	</element>
	<element name="KeyRelationship">
		<annotation>
			<documentation>Identifies if the relationship between the Framework and the Attribute datasets are 1:1 or 1:many.  “one” indicates that there is at most one record in the Attribute dataset for every key in the Framework dataset.  “many” indicates that there may be more than one record in the Attribute dataset for every key in the Framework dataset.</documentation>
		</annotation>
		<simpleType>
			<restriction base="string">
				<enumeration value="one"/>
				<enumeration value="many"/>
			</restriction>
		</simpleType>
	</element>
	<element name="Measure">
		<annotation>
			<documentation>Data consists of measurements of some characteristic attributable to the spatial features</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element ref="gls:UOM"/>
				<element ref="gls:Exceptions" minOccurs="0"/>
			</sequence>
			<attribute name="type" use="required">
				<annotation>
					<documentation>Datatype, as defined by XML schema.</documentation>
				</annotation>
				<simpleType>
					<restriction base="string">
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#decimal"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#float"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#double"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="length" type="nonNegativeInteger" use="required">
				<annotation>
					<documentation>Length of the field, in characters.</documentation>
				</annotation>
			</attribute>
		</complexType>
	</element>
	<element name="Nominal">
		<annotation>
			<documentation>Data consists of unique names for spatial features</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element name="Classes">
					<annotation>
						<documentation>Valid nominal classes for this attribute.</documentation>
					</annotation>
					<complexType>
						<sequence>
							<element ref="gls:Title"/>
							<element ref="gls:Abstract"/>
							<element ref="gls:Documentation" minOccurs="0"/>
							<element name="Value" maxOccurs="unbounded">
								<annotation>
									<documentation>Valid (non-null) values.</documentation>
								</annotation>
								<complexType>
									<sequence>
										<element ref="gls:Identifier">
											<annotation>
												<documentation>Text string found in the V elements of this attribute</documentation>
											</annotation>
										</element>
										<element ref="gls:Title"/>
										<element ref="gls:Abstract"/>
										<element ref="gls:Documentation" minOccurs="0"/>
									</sequence>
								</complexType>
							</element>
						</sequence>
					</complexType>
				</element>
				<element ref="gls:Exceptions" minOccurs="0"/>
			</sequence>
			<attribute name="type" use="required">
				<annotation>
					<documentation>Datatype, as defined by XML schema.</documentation>
				</annotation>
				<simpleType>
					<restriction base="string">
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#string"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#boolean"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#integer"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#decimal"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#float"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#double"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#datetime"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="length" type="nonNegativeInteger">
				<annotation>
					<documentation>Length of the field, in characters.</documentation>
				</annotation>
			</attribute>
		</complexType>
	</element>
	<element name="Ordinal">
		<annotation>
			<documentation>Ordered classifications data</documentation>
		</annotation>
		<complexType>
			<sequence>
				<element name="Classes">
					<annotation>
						<documentation>Valid ordinal classes for this attribute.</documentation>
					</annotation>
					<complexType>
						<sequence>
							<element ref="gls:Title"/>
							<element ref="gls:Abstract"/>
							<element ref="gls:Documentation" minOccurs="0"/>
							<element name="Value" maxOccurs="unbounded">
								<annotation>
									<documentation>Valid (non-null) values.</documentation>
								</annotation>
								<complexType>
									<sequence>
										<element ref="gls:Identifier">
											<annotation>
												<documentation>Text string found in the V elements of this attribute</documentation>
											</annotation>
										</element>
										<element ref="gls:Title"/>
										<element ref="gls:Abstract"/>
										<element ref="gls:Documentation" minOccurs="0"/>
									</sequence>
									<attribute name="rank" type="nonNegativeInteger" use="required">
										<annotation>
											<documentation>Rank order of this value, from lowest = 1 to highest.</documentation>
										</annotation>
									</attribute>
								</complexType>
							</element>
						</sequence>
					</complexType>
				</element>
				<element ref="gls:Exceptions" minOccurs="0"/>
			</sequence>
			<attribute name="type" use="required">
				<annotation>
					<documentation>Datatype, as defined by XML schema.</documentation>
				</annotation>
				<simpleType>
					<restriction base="string">
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#string"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#integer"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#decimal"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#float"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#double"/>
						<enumeration value="http://www.w3.org/TR/xmlschema-2/#datetime"/>
					</restriction>
				</simpleType>
			</attribute>
			<attribute name="length" type="nonNegativeInteger">
				<annotation>
					<documentation>Length of the field, in characters.</documentation>
				</annotation>
			</attribute>
		</complexType>
	</element>
	<element name="Organization" type="string">
		<annotation>
			<documentation>Human-readable name of the organization responsible for maintaining this object.</documentation>
		</annotation>
	</element>
	<element name="Title" type="string">
		<annotation>
			<documentation>Human-readable short description suitable to display on a pick list, legend, and/or on mouseover.</documentation>
		</annotation>
	</element>
	<element name="ReleaseDate" type="date">
		<annotation>
			<documentation>Date of publication.</documentation>
		</annotation>
	</element>
	<element name="Row">
		<complexType>
			<sequence>
				<element ref="gls:K"/>
				<element ref="gls:V" maxOccurs="unbounded">
					<annotation>
						<documentation>Values that apply to this spatial key identified for this row, in the same sequence as the attribute descriptions above.</documentation>
					</annotation>
				</element>
			</sequence>
		</complexType>
	</element>
	<element name="Rowset">
		<complexType>
			<annotation>
				<documentation>Rowset type defines a section for a dataset. Rowset can be presented more than once. However the efficient use of Rowset will be once per GetData response </documentation>
			</annotation>
			<sequence>
				<element ref="gls:Row" maxOccurs="unbounded">
					<annotation>
						<documentation>Dataset Rows</documentation>
					</annotation>
				</element>
			</sequence>
		</complexType>
	</element>
	<element name="UOM" type="ows:DomainMetadataType">
		<annotation>
			<documentation>Unit of Measure</documentation>
		</annotation>
	</element>
	<element name="V">
		<annotation>
			<documentation>Value of a specified attribute for the geospatial identifier for this Row.  When this value is null (indicated with the null attribute) an identification of the reason may be included in the content of this element.</documentation>
		</annotation>
		<complexType>
			<simpleContent>
				<extension base="string">
					<attribute name="aid" type="string" use="optional">
						<annotation>
							<documentation>Attribute identifier, namely the corresponding AttributeName </documentation>
						</annotation>
					</attribute>
					<attribute name="null" type="boolean" default="false">
						<annotation>
							<documentation>Boolean value, when present and "true" indicates that this particular value is missing for some reason, and the contents of the element must be processed accordingly.  </documentation>
						</annotation>
					</attribute>
				</extension>
			</simpleContent>
		</complexType>
	</element>
	<element name="Values">
		<complexType>
			<choice>
				<element ref="gls:Nominal"/>
				<element ref="gls:Ordinal"/>
				<element ref="gls:Count"/>
				<element ref="gls:Measure"/>
			</choice>
		</complexType>
	</element>
</schema>

