http://www.w3.org/XML/1998/namespace
http://www.w3.org/1999/xlink
http://purl.org/dc/elements/1.1/
http://www.w3.org/XML/1998/namespace
<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="xml.xsd"/>
http://www.w3.org/1999/xlink
<xs:import namespace="http://www.w3.org/1999/xlink" schemaLocation="xlink.xsd"/>
http://purl.org/dc/elements/1.1/
<xs:import namespace="http://purl.org/dc/elements/1.1/" schemaLocation="dc.xsd"/>
In DAP2 and DAP4, a dataset is defined as a collection of variables, each of which is completely described by a tuple that consists of a name, type and value(s) along with a hierarchical collection of 'attributes' that themselves are made up of name-type-value(s) tuples. The variables are organized in a hierarchy.
The Dataset document is a text/xml representatin of those variables and their organiation within the dataset.
Element names that start with capital letters correspond to parts of the DAP4 data model while those that start with lowercase letters are used for document structure and syntax.
DAP 4.0 introduces SharedDimension, Group, Opaque, 64-bit integers and UnsignedByte. In addition: The syntax for Array has been changed so that it's easier for processing software to figure out the type of an array; Grids have been generalized so that there can be any number of 'Array' parts (and the Maps may be multi-dimensional); and the Attribute type OtherXML has been made its own element (it's no longer a type of 'Attribute').
<xs:element name="Dataset" type="DatasetT"> </xs:element>
This is the XML representation of a data source in DAP 4.
Note that the 'blob' element is only present when this is used as the prefix for the Data response.
Grammar: ( OtherXML*, Attribute*, Group+, blob? )
Element attributes:
<xs:complexType name="DatasetT"> <xs:sequence> <xs:group ref="Metadata"/> <xs:element name="Group" type="GroupT" minOccurs="1" maxOccurs="unbounded"/> <xs:element name="blob" type="BlobT" minOccurs="0" maxOccurs="1"/> </xs:sequence> <xs:attribute name="name" type="xs:string" use="required"/> <xs:attribute name="dapVersion" type="xs:string" use="required"/> <xs:attribute ref="xml:base" use="required"/> </xs:complexType>
<xs:group name="Metadata"> <xs:sequence> <xs:element name="OtherXML" type="OtherXmlT" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="Attribute" type="AttributeT" minOccurs="0" maxOccurs="unbounded"/> </xs:sequence> </xs:group>
<xs:complexType name="AttributeT"> <xs:choice> <xs:sequence> <xs:element name="value" type="xs:string" maxOccurs="unbounded"/> </xs:sequence> <xs:sequence> <xs:group ref="Metadata"/> </xs:sequence> </xs:choice> <xs:attribute name="name" type="xs:string" use="required"/> <xs:attribute name="type" type="AttributeTypeT" use="required"/> <xs:attribute name="namespace" type="xs:string" use="optional"> </xs:attribute> </xs:complexType>
<xs:simpleType name="CardinalT">
<xs:restriction base="xs:string">
<xs:enumeration value="Byte"/>
<xs:enumeration value="UByte"/>
<xs:enumeration value="Int16"/>
<xs:enumeration value="UInt16"/>
<xs:enumeration value="Int32"/>
<xs:enumeration value="UInt32"/>
<xs:enumeration value="Int64"/>
<xs:enumeration value="UInt64"/>
<xs:enumeration value="Float32"/>
<xs:enumeration value="Float64"/>
<xs:enumeration value="String"/>
<xs:enumeration value="Url"/>
<xs:enumeration value="Enum"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="OpaqueT">
<xs:restriction base="xs:string">
<xs:enumeration value="Opaque"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="ContainerT">
<xs:restriction base="xs:string">
<xs:enumeration value="Container"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="AttributeTypeT"> <xs:union memberTypes="CardinalT ContainerT"/> </xs:simpleType>
<xs:complexType name="OtherXmlT">
<xs:sequence>
<xs:any
namespace="##other"
minOccurs="1"
maxOccurs="unbounded"
processContents="lax"/>
</xs:sequence>
<xs:attribute name="name" type="xs:string"/>
<xs:anyAttribute
processContents="lax"
namespace="##other"/>
</xs:complexType>
<xs:complexType name="GroupT"> <xs:sequence> <xs:group ref="Metadata"/> <xs:element name="Group" type="GroupT" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="Dimension" type="DimensionT" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="Enumeration" type="EnumerationT" minOccurs="0" maxOccurs="unbounded"/> <xs:group ref="AllVariableTypes" minOccurs="1" maxOccurs="unbounded"/> </xs:sequence> <xs:attribute name="name" type="xs:string" default="root"/> </xs:complexType>
<xs:complexType name="DimensionT"> <xs:attribute name="name" type="xs:string" use="required"/> <xs:attribute name="size" type="xs:integer" use="required"/> </xs:complexType>
<xs:complexType name="EnumerationElementT"> <xs:attribute name="name" type="xs:string" use="required"/> <xs:attribute name="value" type="xs:string" use="required"/> </xs:complexType>
<xs:complexType name="EnumerationT"> <xs:choice> <xs:element name="elt" type="EnumerationElementT" minOccurs="1" maxOccurs="unbounded"/> </xs:choice> <xs:attribute name="name" type="xs:string" use="required"/> </xs:complexType>
<xs:group name="CardinalTypes"> <xs:choice> <xs:element name="Byte" type="BaseType"/> <xs:element name="UByte" type="BaseType"/> <xs:element name="Int16" type="BaseType"/> <xs:element name="UInt16" type="BaseType"/> <xs:element name="Int32" type="BaseType"/> <xs:element name="UInt32" type="BaseType"/> <xs:element name="Int64" type="BaseType"/> <xs:element name="UInt64" type="BaseType"/> <xs:element name="Float32" type="BaseType"/> <xs:element name="Float64" type="BaseType"/> <xs:element name="String" type="BaseType"/> <xs:element name="Url" type="BaseType"/> <xs:element name="Enum" type="EnumT"/> <xs:element name="Opaque" type="OpaqueT"/> </xs:choice> </xs:group>
<xs:group name="ArrayVariableTypes"> <xs:choice> <xs:group ref="CardinalTypes"/> <xs:element name="Structure" type="StructureT"/> </xs:choice> </xs:group>
<xs:group name="AllVariableTypes"> <xs:choice> <xs:group ref="ArrayVariableTypes"/> <xs:element name="Array" type="ArrayT" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="Grid" type="GridT" minOccurs="0" maxOccurs="unbounded"/> <xs:element name="Sequence" type="SequenceT" minOccurs="0" maxOccurs="unbounded"/> </xs:choice> </xs:group>
<xs:complexType name="BaseType"> <xs:sequence> <xs:group ref="Metadata"/> </xs:sequence> <xs:attribute name="name" type="xs:string"/> <xs:attribute name="id" type="xs:string" form="qualified"/> </xs:complexType>
<xs:complexType name="ArrayDimensionT"> <xs:attribute name="name" type="xs:string"/> <xs:attribute name="size" type="xs:integer"/> <xs:attribute name="ref" type="xs:string"/> </xs:complexType>
<xs:complexType name="EnumT"> <xs:complexContent> <xs:extension base="BaseType"> <xs:attribute name="type" type="xs:string" use="required"/> </xs:extension> </xs:complexContent> </xs:complexType>
<xs:complexType name="dimensionsT"> <xs:choice> <xs:element name="dim" type="ArrayDimensionT" minOccurs="1" maxOccurs="unbounded"/> </xs:choice> </xs:complexType>
<xs:complexType name="arrayTypeT"> <xs:choice> <xs:group ref="ArrayVariableTypes" minOccurs="1" maxOccurs="1"/> </xs:choice> </xs:complexType>
<xs:complexType name="ArrayT"> <xs:complexContent> <xs:extension base="BaseType"> <xs:sequence> <xs:element name="type" type="arrayTypeT" minOccurs="1" maxOccurs="1"/> <xs:element name="dimensions" type="dimensionsT" minOccurs="1" maxOccurs="1"/> </xs:sequence> </xs:extension> </xs:complexContent> </xs:complexType>
<xs:complexType name="GridT"> <xs:complexContent> <xs:extension base="BaseType"> <xs:sequence> <xs:element name="Array" type="ArrayT" minOccurs="1" maxOccurs="unbounded"/> <xs:element name="Map" type="MapT" minOccurs="1" maxOccurs="unbounded"/> </xs:sequence> </xs:extension> </xs:complexContent> </xs:complexType>
<xs:complexType name="MapT"> <xs:complexContent> <xs:extension base="BaseType"> <xs:sequence> <xs:element name="dimensions" type="dimensionsT" minOccurs="1" maxOccurs="1"/> </xs:sequence> <xs:attribute name="type" type="CardinalT" use="required"/> </xs:extension> </xs:complexContent> </xs:complexType>
<xs:complexType name="allTypeT"> <xs:complexContent> <xs:extension base="BaseType"> <xs:group ref="AllVariableTypes" minOccurs="1" maxOccurs="unbounded"/> </xs:extension> </xs:complexContent> </xs:complexType>
The 'Blob' element is used to point to an associated data document. When DAP is used to access metadata only for a data source, no 'blob' element will be present. However, when a request for data is made, the Dataset element holds a description of the data values and the blob points to a place where those values will be found. In DAP4 the Blob element refers to binary (application/octet-stream) part within a multi-part MIME document or it refers to a separate document, possibly not imediately available. The latter case is included to support asynchronous responses (i.e., responses that cannot be returned quickly). See http://www.w3.org/TR/xlink11/.
If present, the
Examples of the
<dc:date>1994-11-05T13:15:30Z</dc:date>
<dc:date>1994-11-05T13:15:30Z/1994-11-06T00:00:00Z</dc:date>
Element attributes:
<xs:complexType name="BlobT"> <xs:all> <xs:element ref="dc:date" minOccurs="0"/> </xs:all> <xs:attribute ref="xlink:type" use="optional" default="simple"/> <xs:attribute ref="xlink:href" use="required"/> <xs:attribute ref="xlink:role" use="optional"/> </xs:complexType>