2. majas-application.xsd

<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
    xmlns:ns="http://www.w3.org/1999/xhtml" 
    xmlns:hfp="http://www.w3.org/2001/XMLSchema-hasFacetAndProperty" 
    targetNamespace="http://www.majas.org/schema/2006/configuration/" 
    xmlns:mc="http://www.majas.org/schema/2006/configuration/">

  <xsd:annotation>
    <xsd:documentation xml:lang="en">Configuration Copyright 2006 DFC NV,
    K.U.Leuven. All rights reserved.</xsd:documentation>
  </xsd:annotation>




  <!-- ================  APPLICATION ================ -->

  <xsd:complexType name="urlType">
    <xsd:annotation>
      <xsd:documentation>The application name that is used in the
        request URL's, and the reference to the name used for everything else.
        Mind that this reference needs to match the application's real name.
      </xsd:documentation>
      </xsd:annotation>
      <xsd:attribute name="ref" type="xsd:string" use="required" />
      <xsd:attribute name="value" type="xsd:string" use="required" />
  </xsd:complexType>


  <xsd:complexType name="backgroundColorType">
    <xsd:annotation>
      <xsd:documentation xml:lang="en">The background color expression. The color is specified using the Hexadecimal RGB value. White, e.g. is 
      "#FFFFFF" .</xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>


  <xsd:complexType name="lineSelectStyleType">  
    <xsd:annotation>
      <xsd:documentation xml:lang="en">The CSS expression applied when a
      line feature is selected.</xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>


  <xsd:complexType name="pointSelectStyleType">  
    <xsd:annotation>
      <xsd:documentation xml:lang="en">The CSS expression applied when a
      point feature is selected.</xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>


  <xsd:complexType name="polygonSelectStyleType">  
    <xsd:annotation>
      <xsd:documentation xml:lang="en">The CSS expression applied when a
      polygon feature is selected.</xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>


  <xsd:complexType name="appNameType">  
    <xsd:annotation>
      <xsd:documentation xml:lang="en">The name of the MAJAS 
      application. This should be the same as the 'ref' attribute 
      in the url tag.(TODO: the ref attribute in the url tag, should be 
      eliminated)</xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>


  <xsd:simpleType name="crsRestrictionType">
    <xsd:annotation>
      <xsd:documentation xml:lang="en">Specifies a coordinate reference
      system. E.g. "EPSG:31300" (Belgian Lambert 72). It must start with a String that identifies
      the authority or source for the reference system definition. (TODO: add
      a string pattern that values must respect).</xsd:documentation>
    </xsd:annotation>
    <xsd:restriction base="xsd:string">
      <xsd:length value="10"/>
    </xsd:restriction>
  </xsd:simpleType>


  <xsd:complexType name="crsType">  
    <xsd:attribute name="value" type="mc:crsRestrictionType" use="required"/>
  </xsd:complexType>


  <xsd:complexType name="preferredWMSFormatType">  
    <xsd:annotation>
      <xsd:documentation xml:lang="en">What format is the preferred format 
      for WMS layers. Choose between "image/jpeg", "image/gif" and "image/png".
      </xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>

  <xsd:complexType name="layerFactoryType">  
    <xsd:annotation>
      <xsd:documentation xml:lang="en">Classname as string where the
      LayerFactory for this application can be found.
      </xsd:documentation>
    </xsd:annotation>
    <xsd:attribute name="value" type="xsd:string" use="required"/>
  </xsd:complexType>

  <xsd:complexType name="usersType">
    <xsd:sequence>
      <xsd:element maxOccurs="unbounded" name="user">
        <xsd:complexType>
          <xsd:annotation>
            <xsd:documentation xml:lang="en">A user that is allowed on 
            this application.</xsd:documentation>
          </xsd:annotation>
          <xsd:attribute name="ref" type="xsd:string" use="required">
            <xsd:annotation>
              <xsd:documentation xml:lang="en">The user name. For each user there must exist a [user name].xml xml file in directory data/ggis/users.</xsd:documentation>
            </xsd:annotation>
          </xsd:attribute>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>


  <xsd:element name="application">
    <xsd:complexType>
      <xsd:sequence>
      
        <xsd:element name="url" type="mc:urlType" />

        <xsd:element name="backgroundColor"	type="mc:backgroundColorType" />

        <xsd:element name="lineSelectStyle" type="mc:lineSelectStyleType" />

        <xsd:element name="pointSelectStyle" type="mc:pointSelectStyleType" />

        <xsd:element name="polygonSelectStyle" type="mc:polygonSelectStyleType" />

        <xsd:element name="name" type="mc:appNameType" />

        <xsd:element name="crs" type="mc:crsType" />

        <xsd:element name="preferredWMSFormat" type="mc:preferredWMSFormatType" />

        <xsd:element name="layerFactory" type="mc:layerFactoryType" />

        <xsd:element name="users" type="mc:usersType">
          <xsd:annotation>
            <xsd:documentation>The list of users that are recognized by
            this application. Only these users are allowed to use the 
            application.</xsd:documentation>
          </xsd:annotation>
        </xsd:element>

        <xsd:element name="layers" type="mc:layersType"/>

        <xsd:element name="gridConfig" type="mc:gridConfigType"/>

      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>






  <!-- ================  BASE-LAYER ================ -->


  <xsd:complexType name="baseLayerType">
    <xsd:annotation>
      <xsd:documentation xml:lang="en">This is the base type for layers. It defines what NodeLayers and LeafyLayers have in common.</xsd:documentation>
    </xsd:annotation>
    <xsd:sequence>

            <xsd:element name="layerName">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">The name of the layer (used
                in the TOC and legend).</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="defaultVisible">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">Set to "true" to make the
                layer visible when the application initialises (start of user
                session). That is, a layer can only be visible between certain 
                scale-ranges (see scaleRange in the leafyLayer). For node-layers, 
                it is recommended to always set this value to 'true'.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:boolean" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="displayOrderMap">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">The order in which the map is
                drawn on the screen.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:positiveInteger"
                               use="required">
                  <xsd:annotation>
                    <xsd:documentation>Lower number means that the layer is
                    rendered later.</xsd:documentation>
                  </xsd:annotation>
                </xsd:attribute>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="displayOrderTOC">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">The order where the layer is
                shown in the Table of Content (layer control
                component)</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:positiveInteger"
                               use="required">
                  <xsd:annotation>
                    <xsd:documentation>Lower number means that the layer is
                    displayed higher in the ToC.</xsd:documentation>
                  </xsd:annotation>
                </xsd:attribute>
              </xsd:complexType>
            </xsd:element>

    </xsd:sequence>

    <xsd:attribute name="id" type="xsd:positiveInteger" use="required">
      <xsd:annotation>
        <xsd:documentation>The identifier for the layer. Layer id's must
        be unique within the application.xml</xsd:documentation>
      </xsd:annotation>
    </xsd:attribute>

  </xsd:complexType>


  <xsd:complexType name="layersType">
    <xsd:sequence>
      <xsd:element maxOccurs="unbounded" name="layer" type="mc:baseLayerType" />
    </xsd:sequence>
  </xsd:complexType>





  <!-- ================  NODE-LAYER ================ -->

  <xsd:complexType name="nodeLayerType">
    <xsd:annotation>
      <xsd:documentation xml:lang="en">NodeLayers have child layers but are not directly associated with feature types.</xsd:documentation>
    </xsd:annotation>
    <xsd:complexContent>
      <xsd:extension base="mc:baseLayerType">
        <xsd:sequence>

          <xsd:element name="childLayers" type="mc:layersType"/>

        </xsd:sequence>
      </xsd:extension>
    </xsd:complexContent>
  </xsd:complexType>
  
  



  <!-- ================  LEAFY-LAYER ================ -->


  <xsd:simpleType name="layerTypeType">
    <xsd:restriction base="xsd:positiveInteger">
      <xsd:minInclusive value="1"/>
      <xsd:maxInclusive value="4"/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="crudValueType">
    <xsd:restriction base="xsd:nonNegativeInteger">
      <xsd:minInclusive value="0"/>
      <xsd:maxInclusive value="7"/>
    </xsd:restriction>
  </xsd:simpleType>


  <xsd:complexType name="leafyLayerType">
    <xsd:annotation>
      <xsd:documentation xml:lang="en">LeafyLayers are directly associated with feature types. They do not have child layers.</xsd:documentation>
    </xsd:annotation>
    <xsd:complexContent>
      <xsd:extension base="mc:baseLayerType">
      
        <xsd:sequence>

            <xsd:element name="activatable">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">Set to "true", if the layer
                can be made active.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:boolean" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="active">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">Set to "true" to make the
                layer active when the application initialises (start of user
                session). Only one layer can be active at a time!</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:boolean" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="exportable">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">Set to true, to allow the
                user to export the layer data to XML.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:boolean" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="urlProperty">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">A property from the 
                featureType that contains an url.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="layerType">
              <xsd:annotation>
                <xsd:documentation>Determines the type of layer (point=2, 
                line=3, polygon=4, or raster data = 1)</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="mc:layerTypeType"
                               use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="viewScale">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">The scale range at which
                features are rendered in the map. The scale range is
                determined by the element's min and max attributes. Values for
                these attributes are in pixels per meter. Outside this range, 
                the entire layer will be invisible.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="min" type="xsd:decimal" use="required"/>
                <xsd:attribute name="max" type="xsd:decimal" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="showLabels">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">Determines whether labels are
                shown when the application starts in the user's
                browser.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:boolean" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="editableSupported">
              <xsd:annotation>
                <xsd:documentation>Determines whether the layer can be edited.
                Editing requires sufficient user's
                privileges.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:boolean" use="required"/>
              </xsd:complexType>
            </xsd:element>
            
            <xsd:element name="attribFeatureId">
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>
            <xsd:element name="attribVersion">
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>
            <xsd:element name="attribEditDate">
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>
            <xsd:element name="attribUserId">
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>
            <xsd:element name="attribEditState">
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>
            <xsd:element name="attribFlowState">
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="featureType">
              <xsd:annotation>
                <xsd:documentation>The feature type that is the data source of
                this layer. The values of this attribute refers to the
                GeoServer feature type definition.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="crudValue">
              <xsd:annotation>
                <xsd:documentation>Determines what CRUD operations are 
                  possible on this layer. Only applicable if editableSupported 
                  is true.<br/>The system is simple:
                  <ul>
                    <li>Enable creation of new object: +1</li>
                    <li>Enable reading operations: implicit</li>
                    <li>Enable updates on existing objects: +2</li>
                    <li>Enable deletion of existing objects: +4</li>
                  </ul>
                </xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="mc:crudValueType"
                               use="required"/>
              </xsd:complexType>
            </xsd:element>



            <xsd:element name="snappingRules" type="mc:snappingRulesType">
              <xsd:annotation>
                <xsd:documentation xml:lang="en">The (ordered) list of
                snapping rules that are applicable when features are
                edited.</xsd:documentation>
              </xsd:annotation>
            </xsd:element>

            <xsd:element name="identifyingAttributes"
                         type="mc:identifyingAttributesType">
              <xsd:annotation>
                <xsd:documentation>The attributes that are used to identify a
                feature.</xsd:documentation>
              </xsd:annotation>
            </xsd:element>

            <xsd:element name="viewableAttributes"
                         type="mc:viewableAttributesType">
              <xsd:annotation>
                <xsd:documentation>The attributes that are shown for a
                feature in more detail. Usualy these are the identifying 
                attributes plus additional, less important 
                attributes.</xsd:documentation>
              </xsd:annotation>
            </xsd:element>

            <xsd:element name="labelConfig" type="mc:labelConfigType">
              <xsd:annotation>
                <xsd:documentation>Determines how the labels are rendered for
                this layer.</xsd:documentation>
              </xsd:annotation>
            </xsd:element>

            <xsd:element name="styleDefs">
              <xsd:annotation>
                <xsd:documentation>The styling information for the layer. It
                consists of a list of StyleDefs.</xsd:documentation>
              </xsd:annotation>

              <xsd:complexType>
                <xsd:sequence>
                  <xsd:element maxOccurs="unbounded" name="styleDef"
                               type="mc:styleDefType">
                    <xsd:annotation>
                      <xsd:documentation>This element describes a single
                      styling for a set of features.</xsd:documentation>
                    </xsd:annotation>
                  </xsd:element>
                </xsd:sequence>
              </xsd:complexType>
            </xsd:element>

        </xsd:sequence>
      </xsd:extension>
    </xsd:complexContent>
  </xsd:complexType>





  <!-- ================  SNAPPING RULES ================ -->

  <xsd:complexType name="snappingRulesType">
    <xsd:sequence>
      <xsd:element maxOccurs="unbounded" minOccurs="0" name="snappingRule">
        <xsd:complexType>
          <xsd:sequence>
          
            <xsd:element name="snapDistance">
              <xsd:annotation>
                <xsd:documentation>The search distance in
                meter.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:decimal" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="snappingLayer">
              <xsd:annotation>
                <xsd:documentation>Identifies the layer to which features are
                snapped. Use the layerName, not the ID.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="snappingType">
              <xsd:annotation>
                <xsd:documentation>Only one type known at this 
                time, i.e. snapping to vertices (=1).</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:positiveInteger"
                               use="required"/>
              </xsd:complexType>
            </xsd:element>
            
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>





  <!-- ================  ATTRIBUTES ================ -->

  <xsd:complexType name="identifyingAttributesType">
    <xsd:sequence>
      <xsd:element maxOccurs="unbounded" minOccurs="0"
                   name="identifyingAttribute">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="attributeLabel">
              <xsd:annotation>
                <xsd:documentation>The name that is used in the application
                for this attribute.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="attributeName">
              <xsd:annotation>
                <xsd:documentation>The name of the attribute in the data store (column
                name).</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>
            
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>


  <xsd:complexType name="viewableAttributesType">
    <xsd:sequence>
      <xsd:element maxOccurs="unbounded" minOccurs="0"
                   name="viewableAttribute">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="attributeLabel">
              <xsd:annotation>
                <xsd:documentation>The name that is used in the application
                for this attribute.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element name="attributeName">
              <xsd:annotation>
                <xsd:documentation>The name of the attribute in the data store (column
                name).</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

            <xsd:element minOccurs="0" name="attributeValidator">
              <xsd:annotation>
                <xsd:documentation>Validation expression that must validate to
                true. Geometrical validation expressions are not allowed 
                here. For more information consult the Configuration Manual.</xsd:documentation>
              </xsd:annotation>
              <xsd:complexType>
                <xsd:attribute name="value" type="xsd:string" use="required"/>
              </xsd:complexType>
            </xsd:element>

          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>





  <!-- ================  LABEL CONFIG ================ -->

  <xsd:complexType name="labelConfigType">
    <xsd:sequence>
    
      <xsd:element name="labelAttributeName">
        <xsd:annotation>
          <xsd:documentation>The property (attribute) that holds the content
          for the feature label.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:string" use="required">
            <xsd:annotation>
              <xsd:documentation>The name of the feature attribute in the data store (column
              name).</xsd:documentation>
            </xsd:annotation>
          </xsd:attribute>
        </xsd:complexType>
      </xsd:element>

    </xsd:sequence>
  </xsd:complexType>





  <!-- ================  STYLE DEFINITION ================ -->

  <xsd:complexType name="styleDefType">
    <xsd:sequence>
    
      <xsd:element name="id">
        <xsd:annotation>
          <xsd:documentation>Identifier for the style. Style identifiers must
          be unique within the layer.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:integer"
                         use="required"/>
        </xsd:complexType>
      </xsd:element>

      <xsd:element name="name">
        <xsd:annotation>
          <xsd:documentation>The name that is given in the map legend to the
          set of features that are styled according to this
          styleDef.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:string" use="required"/>
        </xsd:complexType>
      </xsd:element>

      <xsd:element name="svgStyle">
        <xsd:annotation>
          <xsd:documentation>The CSS styling expression.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:string" use="required"/>
        </xsd:complexType>
      </xsd:element>

      <xsd:element name="showInLegend">
        <xsd:annotation>
          <xsd:documentation>Determines whether or not this style should be
          visible in the lagend on the client.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:boolean" use="required"/>
        </xsd:complexType>
      </xsd:element>

      <xsd:element name="formula">
        <xsd:annotation>
          <xsd:documentation>The criteria expression that defines the set of
          features that is labeled according to this styleDef. If empty, the
          this styleDef will be applied to all features in the
          layer. Geometrical expressions are not allowed 
          here. For more information consult the Configuration Manual.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:string" use="required"/>
        </xsd:complexType>
      </xsd:element>
      
    </xsd:sequence>
  </xsd:complexType>






  <!-- ================  GRID CONFIGURATION ================ -->

  <xsd:complexType name="gridConfigType">
    <xsd:annotation>
      <xsd:documentation>Configures the spatial index that is used for raster
      and vector data.</xsd:documentation>
    </xsd:annotation>

    <xsd:sequence>
    
      <xsd:element name="transformationFunction">
        <xsd:annotation>
          <xsd:documentation>The transformation between the SVG coordinate
          space and the geographic coordinate reference system
          (crs).</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="value" type="xsd:string" use="required"/>
        </xsd:complexType>
      </xsd:element>

      <xsd:element name="fullMapExtent">
        <xsd:annotation>
          <xsd:documentation>The maximum map extent that is visible in the
          application. The extent is specified by minX, maxX, minY and maxY.
          The units are in the coordinate reference system identified in the
          crs element.</xsd:documentation>
        </xsd:annotation>
        <xsd:complexType>
          <xsd:attribute name="maxX" type="xsd:decimal" use="required"/>
          <xsd:attribute name="minX" type="xsd:decimal" use="required"/>
          <xsd:attribute name="minY" type="xsd:decimal" use="required"/>
          <xsd:attribute name="maxY" type="xsd:decimal" use="required"/>
        </xsd:complexType>
      </xsd:element>

      <xsd:element name="rasterZoomLevels">
        <xsd:annotation>
          <xsd:documentation>The index is composed of a list of
          rasterZoomLevels. The first level partitions the fullMapExtent in 4
          tiles, the second subdivides each tile in 4, and so
          on.</xsd:documentation>
        </xsd:annotation>

        <xsd:complexType>
          <xsd:sequence>
          
            <xsd:element maxOccurs="unbounded" name="rasterZoomLevel">
              <xsd:complexType>
                <xsd:annotation>
                  <xsd:documentation>This element defines a zoom level for the
                  spatial index. If a data request is sent by the client with
                  a current scale in the range of rasterZoomLevel, than the
                  received data is stored at this level. The min and max
                  viewscales are expressed in pixels /
                  meter</xsd:documentation>
                </xsd:annotation>

                <xsd:sequence>
                
                  <xsd:element name="minViewScale">
                    <xsd:complexType>
                      <xsd:attribute name="value" type="xsd:string"/>
                    </xsd:complexType>
                  </xsd:element>

                  <xsd:element name="maxViewScale">
                    <xsd:complexType>
                      <xsd:attribute name="value" type="xsd:string"/>
                    </xsd:complexType>
                  </xsd:element>
                  
                </xsd:sequence>
                
              </xsd:complexType>
            </xsd:element>
            
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:sequence>
  </xsd:complexType>
</xsd:schema>