<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
  <xs:element name="ClassDefinition" type="ClassDefinition">
    <xs:annotation>
      <xs:documentation>A FDO Class Definition.</xs:documentation>
    </xs:annotation>
  </xs:element>
  <xs:complexType name="ClassDefinition">
    <xs:annotation>
      <xs:documentation>A FDO Class Definition.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Name" type="xs:string">
        <xs:annotation>
          <xs:documentation>The name of this class definition</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Description" type="xs:string">
        <xs:annotation>
          <xs:documentation>The description of this class definition</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="IsAbstract" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>Indicates if this class definition is abstract</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="IsComputed" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>Indicates if this class definition is computed</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DefaultGeometryPropertyName" type="xs:string">
        <xs:annotation>
          <xs:documentation>The name of the designated geometry property of this class definition</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Properties" type="PropertyDefinitionCollection">
        <xs:annotation>
          <xs:documentation>The collection of properties in this class definition</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="PropertyDefinitionCollection">
    <xs:annotation>
      <xs:documentation>A collection of property definitions</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Property" type="PropertyDefinition" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="PropertyDefinition">
    <xs:annotation>
      <xs:documentation>A FDO property definition</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Name" type="xs:string">
        <xs:annotation>
          <xs:documentation>The name of this property definition</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Description" type="xs:string">
        <xs:annotation>
          <xs:documentation>The description of this property definition</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="PropertyType" type="xs:integer">
        <xs:annotation>
          <xs:documentation>The type of this property definition. The value here is within the same set of values from MgFeaturePropertyType</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="IsIdentity" type="xs:boolean">
        <xs:annotation>
          <xs:documentation>Indicates if this property is an identity property</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DataType" type="xs:integer" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The data type of this data property. The value here is within the same set of values from MgPropertyType. Only applicable if this is a data property</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DefaultValue" type="xs:string" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The default value for this data property. Only applicable if this is a data property and the data type is string</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Length" type="xs:integer" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The maximum length for this data property. Only applicable if this is a data property and the data type is string</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Nullable" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Indicates if this property is nullable. Only applicable if this is a raster or data property.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ReadOnly" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Indicates if this property is read-only. Only applicable if this is a raster, geometry or data property.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="IsAutoGenerated" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Indicates if this property is auto-generated. Only applicable if this is a data property and the data type is int.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Precision" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The precision (total number of digits) of this property. Only applicable if this is a data property and the data type is decimal.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Scale" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The scale (number of digits to the right of the decimal point) of this property. Only applicable if this is a data property and the data type is decimal.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="SpatialContextAssociation" type="xs:string" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The spatial context name associated with this geometric property. Only applicable if this is a raster or geometry property.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="GeometryTypes" type="xs:integer" minOccurs="0">
        <xs:annotation>
          <xs:documentation>A bitmask that indicates the types which specify the categories of the geometries (point, line, surface, solid) that can be stored in this geometric property. Values here come from MgFeatureGeometricType.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="SpecificGeometryTypes" type="GeometryTypeInfo" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Indicates the specific geometry types that can be stored in this geometric property. Values here come from MgGeometryType.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="HasElevation" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Indicates if this property has elevation. Only applicable if this is a geometry property.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="HasMeasure" type="xs:boolean" minOccurs="0">
        <xs:annotation>
          <xs:documentation>Indicates if this property has measure. Only applicable if this is a geometry property.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DefaultImageXSize" type="xs:integer" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The default size of the image file in the horizontal direction, in pixels (number of columns)</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DefaultImageYSize" type="xs:integer" minOccurs="0">
        <xs:annotation>
          <xs:documentation>The default size of the image file in the vertical direction, in pixels (number of rows).</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>
  <xs:complexType name="GeometryTypeInfo">
    <xs:annotation>
      <xs:documentation>Defines a list of geometric types</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Type" type="xs:integer" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
  </xs:complexType>
</xs:schema>