JAL-1925 update source version in license
[jalview.git] / schemas / castor-mapping.xsd
index bc8a3a1..0f6ba02 100644 (file)
-<?xml version="1.0" encoding="UTF-8"?>\r
-<!--\r
-   * Jalview - A Sequence Alignment Editor and Viewer (Version 2.5)\r
-   * Copyright (C) 2010 J Procter, AM Waterhouse, G Barton, M Clamp, S Searle\r
-   * \r
-   * This file is part of Jalview.\r
-   * \r
-   * Jalview is free software: you can redistribute it and/or\r
-   * modify it under the terms of the GNU General Public License \r
-   * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.\r
-   * \r
-   * Jalview is distributed in the hope that it will be useful, but \r
-   * WITHOUT ANY WARRANTY; without even the implied warranty \r
-   * of MERCHANTABILITY or FITNESS FOR A PARTICULAR \r
-   * PURPOSE.  See the GNU General Public License for more details.\r
-   * \r
-   * You should have received a copy of the GNU General Public License along with Jalview.  If not, see <http://www.gnu.org/licenses/>.\r
--->\r
-<!--DOCTYPE schema PUBLIC "-//W3C/DTD XML Schema Version 1.0//EN"\r
-    "http://www.w3.org/TR/2000/WD-xmlschema-1-20000225/structures.dtd"-->\r
-    <!--\r
-        Castor Object Mapping XML Schema\r
-        \r
-        Namespace: http://castor.exolab.org/\r
-        System:    http://castor.exolab.org/mapping.xsd\r
-        Public:    -//EXOLAB/Castor Object Mapping Schema Version 1.0//EN\r
-        \r
-        *Note*: This schema is under evolution and subject to change.\r
-        \r
-    -->\r
-    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"\r
-        targetNamespace="http://castor.exolab.org/"\r
-        xmlns="http://castor.exolab.org/"\r
-        version="0.9.4">\r
-        \r
-        <xsd:element name="mapping">\r
-            <xsd:complexType>\r
-                <xsd:sequence>\r
-                    <xsd:element name="description"   type="xsd:string" minOccurs="0" maxOccurs="1" />\r
-                    <xsd:element ref="include"        minOccurs="0" maxOccurs="unbounded" />\r
-                    <xsd:element ref="class"          minOccurs="0" maxOccurs="unbounded" />\r
-                    <xsd:element ref="key-generator"  minOccurs="0" maxOccurs="unbounded" />\r
-                </xsd:sequence>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="include">\r
-            <xsd:complexType>\r
-                <xsd:attribute name="href" type="xsd:string" use="required"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="class">\r
-            <xsd:complexType>\r
-                <xsd:sequence>\r
-                    <xsd:element name="description" type="xsd:string" minOccurs="0" maxOccurs="1" />\r
-                    <xsd:element ref="cache-type"   minOccurs="0" maxOccurs="1" />\r
-                    <xsd:element ref="map-to" minOccurs="0" maxOccurs="1" />\r
-                    <xsd:choice minOccurs="1">\r
-                        <xsd:element ref="field" minOccurs="0" maxOccurs="unbounded"/>\r
-                        <xsd:element ref="container" minOccurs="0" maxOccurs="unbounded"/>\r
-                    </xsd:choice>\r
-                </xsd:sequence>\r
-                <xsd:attribute name="name"     type="xsd:ID"         use="required"/>\r
-                <xsd:attribute name="extends"  type="xsd:IDREF"      use="optional"/>\r
-                <xsd:attribute name="depends"  type="xsd:IDREF"      use="optional"/>\r
-                <xsd:attribute name="identity" type="xsd:NMTOKENS"   use="optional"/>\r
-                <xsd:attribute name="access"   default="shared"    use="optional">\r
-                    <xsd:simpleType>\r
-                        <xsd:restriction base="xsd:string">\r
-                            <xsd:enumeration value="read-only"/>\r
-                            <xsd:enumeration value="shared"/>\r
-                            <xsd:enumeration value="exclusive"/>\r
-                            <xsd:enumeration value="db-locked"/>\r
-                        </xsd:restriction>\r
-                    </xsd:simpleType>\r
-                </xsd:attribute>\r
-                <xsd:attribute name="key-generator" type="xsd:string"   use="optional"/>\r
-                <xsd:attribute name="auto-complete" type="xsd:boolean"  use="optional" default="false"/>\r
-                <xsd:attribute name="verify-constructable" type="xsd:boolean"  use="optional" default="true"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="map-to">\r
-            <xsd:complexType>\r
-                <xsd:attribute name="table"     type="xsd:NMTOKEN"  use="optional"/>\r
-                <xsd:attribute name="xml"       type="xsd:string"   use="optional"/>\r
-                <xsd:attribute name="ns-uri"    type="xsd:string"   use="optional"/>\r
-                <xsd:attribute name="ns-prefix" type="xsd:NMTOKEN"  use="optional"/>\r
-                <xsd:attribute name="ldap-dn"   type="xsd:string"   use="optional"/>\r
-                <xsd:attribute name="ldap-oc"   type="xsd:string"   use="optional"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="field">\r
-            <xsd:complexType>\r
-                <xsd:sequence>\r
-                    <xsd:element name="description"   type="xsd:string" minOccurs="0" maxOccurs="1" />\r
-                    <xsd:element ref="sql"            minOccurs="0" maxOccurs="1"/>\r
-                    <xsd:element ref="bind-xml"       minOccurs="0" maxOccurs="1"/>\r
-                    <xsd:element ref="ldap"           minOccurs="0" maxOccurs="1"/>\r
-                </xsd:sequence>\r
-                \r
-                <xsd:attribute name="name"          type="xsd:string" use="required"/>\r
-                <xsd:attribute name="type"          type="xsd:string" use="optional"/>\r
-                <xsd:attribute name="required"      type="xsd:boolean"  use="optional"   default="false"/>\r
-                <xsd:attribute name="transient"     type="xsd:boolean"  use="optional"   default="false"/>\r
-                <xsd:attribute name="direct"        type="xsd:boolean"  use="optional"   default="false"/>\r
-                <xsd:attribute name="lazy"          type="xsd:boolean"  use="optional"   default="false"/>\r
-                <xsd:attribute name="container"     type="xsd:boolean"  use="optional"/>\r
-                <xsd:attribute name="get-method"    type="xsd:string"  use="optional"/>\r
-                <xsd:attribute name="has-method"    type="xsd:string"  use="optional"/>\r
-                <xsd:attribute name="set-method"    type="xsd:string"  use="optional"/>\r
-                <xsd:attribute name="create-method" type="xsd:string"  use="optional"/>\r
-                <xsd:attribute name="handler"       type="xsd:string"   use="optional"/>\r
-                <xsd:attribute name="collection"    use="optional">\r
-                    <xsd:simpleType>\r
-                        <xsd:restriction base="xsd:string">\r
-                            <xsd:enumeration value="array"/>\r
-                            <xsd:enumeration value="vector"/>\r
-                            <xsd:enumeration value="arraylist"/>\r
-                            <xsd:enumeration value="hashtable"/>\r
-                            <xsd:enumeration value="collection"/>\r
-                            <xsd:enumeration value="set"/>\r
-                            <xsd:enumeration value="map"/>\r
-                            <xsd:enumeration value="enumerate"/>\r
-                        </xsd:restriction>\r
-                    </xsd:simpleType>\r
-                </xsd:attribute>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="container">\r
-            <xsd:complexType>\r
-                <xsd:sequence>\r
-                    <xsd:element name="description" type="xsd:string" minOccurs="0" maxOccurs="1" />\r
-                    <xsd:element ref="field" minOccurs="1"/>\r
-                </xsd:sequence>\r
-                <xsd:attribute name="name"          type="xsd:NMTOKEN" use="required"/>\r
-                <xsd:attribute name="type"          type="xsd:NMTOKEN" use="optional"/>\r
-                <xsd:attribute name="required"      type="xsd:boolean" use="optional"  default="false"/>\r
-                <xsd:attribute name="direct"        type="xsd:boolean" use="optional"  default="false"/>\r
-                <xsd:attribute name="get-method"    type="xsd:NMTOKEN" use="optional"/>\r
-                <xsd:attribute name="set-method"    type="xsd:NMTOKEN" use="optional"/>\r
-                <xsd:attribute name="create-method" type="xsd:NMTOKEN" use="optional"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="sql">\r
-            <xsd:complexType>\r
-                <xsd:attribute name="name"       type="xsd:NMTOKENS"   use="optional"/>\r
-                <xsd:attribute name="type"       type="xsd:string"   use="optional"/>\r
-                <xsd:attribute name="many-table" type="xsd:NMTOKEN"    use="optional"/>\r
-                <xsd:attribute name="many-key"   type="xsd:NMTOKENS"   use="optional"/>\r
-                <xsd:attribute name="read-only"  type="xsd:boolean"    use="optional" default="false"/>\r
-                \r
-                <!-- signals that this field is transient for database mapping (ie should be ignored) -->\r
-                <xsd:attribute name="transient" type="xsd:boolean" use="optional"/>\r
-                \r
-                \r
-                <xsd:attribute name="dirty"  default="check"  use="optional">\r
-                    <xsd:simpleType>\r
-                        <xsd:restriction base="xsd:string">\r
-                            <xsd:enumeration value="check"/>\r
-                            <xsd:enumeration value="ignore"/>\r
-                        </xsd:restriction>\r
-                    </xsd:simpleType>\r
-                </xsd:attribute>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <!--\r
-            The 'bind-xml' element is used for specifying XML specific databinding\r
-            properties and behavior for a specific field. 'bind-xml' may only appear\r
-            as a child of a 'field' element.\r
-        -->\r
-        <xsd:element name="bind-xml">\r
-            <xsd:annotation>\r
-                <xsd:documentation>\r
-                    The 'bind-xml' element is used for specifying XML specific databinding\r
-                    properties and behavior for a specific field. 'bind-xml' may only appear\r
-                    as a child of a 'field' element.\r
-                </xsd:documentation>\r
-            </xsd:annotation>\r
-            <xsd:complexType>\r
-                \r
-                <xsd:sequence>\r
-                    <xsd:element ref="class" minOccurs="0" maxOccurs="1"/>\r
-                    <xsd:element name="property" type="propertyType" minOccurs="0" maxOccurs="unbounded"/>\r
-                </xsd:sequence>\r
-                \r
-                <!--\r
-                    An optional attribute used for specifying the XML name for the\r
-                    field associated with the 'bind-xml' element.\r
-                -->\r
-                <xsd:attribute name="name" type="xsd:QName"  use="optional">\r
-                    <xsd:annotation>\r
-                        <xsd:documentation>\r
-                            An optional attribute used for specifying the XML name for the\r
-                            field associated with the 'bind-xml' element.\r
-                        </xsd:documentation>\r
-                    </xsd:annotation>\r
-                </xsd:attribute>\r
-                \r
-                <xsd:attribute name="type" type="xsd:NMTOKEN"  use="optional"/>\r
-                \r
-                <!--\r
-                    Allows specifying how Castor should automatically determines\r
-                    the XML name of this field when no name has been specified.\r
-                -->\r
-                <xsd:attribute name="auto-naming" use="optional">\r
-                    <xsd:annotation>\r
-                        <xsd:documentation>\r
-                            Allows specifying how Castor should automatically determines\r
-                            the XML name of this field when no name has been specified.\r
-                            In most cases the XML name is determined by using the field name,\r
-                            but in some cases the user may want to use the Class name of\r
-                            the field type. This attribute allows choosing between the\r
-                            two approaches. If this attribute is not specified, the field\r
-                            name is used as the XML name.\r
-                        </xsd:documentation>\r
-                    </xsd:annotation>\r
-                    <xsd:simpleType>\r
-                        <xsd:restriction base="xsd:string">\r
-                            <xsd:enumeration value="deriveByClass"/>\r
-                            <xsd:enumeration value="deriveByField"/>\r
-                        </xsd:restriction>\r
-                    </xsd:simpleType>\r
-                </xsd:attribute>\r
-                \r
-                <!--\r
-                    Allows specifying a nested location path for this field,\r
-                    the value should just be a simplified XPath like value\r
-                    where names are separated by "/".\r
-                -->\r
-                <xsd:attribute name="location" type="xsd:string" use="optional">\r
-                    <xsd:annotation>\r
-                        <xsd:documentation>\r
-                            Allows specifying a nested location path for this field,\r
-                            the value should just be a simplified XPath like value\r
-                            where names are separated by "/".\r
-                        </xsd:documentation>\r
-                    </xsd:annotation>\r
-                </xsd:attribute>\r
-                \r
-                <!-- Allows overriding the matching rule -->\r
-                <xsd:attribute name="matches" type="xsd:string" use="optional"/>\r
-                \r
-                \r
-                <!-- Signal that this field should be marshalled as a reference -->\r
-                <xsd:attribute name="reference" type="xsd:boolean" use="optional"/>\r
-                \r
-                <!-- NodeType for the XML node -->\r
-                <xsd:attribute name="node" use="optional">\r
-                    <xsd:simpleType>\r
-                        <xsd:restriction base="xsd:string">\r
-                            <xsd:enumeration value="attribute"/>\r
-                            <xsd:enumeration value="element"/>\r
-                            <xsd:enumeration value="namespace"/>\r
-                            <xsd:enumeration value="text"/>\r
-                        </xsd:restriction>\r
-                    </xsd:simpleType>\r
-                </xsd:attribute>\r
-                \r
-                <xsd:attribute name="QName-prefix" type="xsd:NMTOKEN" use="optional"/>\r
-                \r
-                <!-- Signal that this field is transient for XML (ie should be ignored) -->\r
-                <xsd:attribute name="transient" type="xsd:boolean" use="optional"/>\r
-                \r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        \r
-        \r
-        <xsd:element name="ldap">\r
-            <xsd:complexType>\r
-                <xsd:attribute name="name" type="xsd:NMTOKEN" use="optional"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="key-generator">\r
-            <xsd:complexType>\r
-                <xsd:sequence>\r
-                    <xsd:element ref="param" minOccurs="0" maxOccurs="unbounded" />\r
-                </xsd:sequence>\r
-                <xsd:attribute name="name"  type="xsd:ID"     use="required"/>\r
-                <xsd:attribute name="alias" type="xsd:string" use="optional"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="cache-type">\r
-            <xsd:complexType>\r
-                <xsd:attribute name="type" type="xsd:string" use="optional" default="count-limited" />\r
-                <xsd:attribute name="capacity" type="xsd:integer" use="optional"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        <xsd:element name="param">\r
-            <xsd:complexType>\r
-                <xsd:attribute name="name"  type="xsd:string"  use="required"/>\r
-                <xsd:attribute name="value" type="xsd:string"  use="required"/>\r
-            </xsd:complexType>\r
-        </xsd:element>\r
-        \r
-        \r
-        <xsd:complexType name="propertyType">\r
-            <xsd:sequence>\r
-                <xsd:element name="name"  type="xsd:string"/>\r
-                <xsd:element name="value" type="xsd:string"/>\r
-            </xsd:sequence>\r
-        </xsd:complexType>\r
-        \r
-        \r
-    </xsd:schema>\r
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Jalview - A Sequence Alignment Editor and Viewer (Version 2.9.0b2)
+ * Copyright (C) 2015 The Jalview Authors
+ * 
+ * This file is part of Jalview.
+ * 
+ * Jalview is free software: you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License 
+ * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
+ *  
+ * Jalview is distributed in the hope that it will be useful, but 
+ * WITHOUT ANY WARRANTY; without even the implied warranty 
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
+ * PURPOSE.  See the GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
+-->
+<!--DOCTYPE schema PUBLIC "-//W3C/DTD XML Schema Version 1.0//EN"
+    "http://www.w3.org/TR/2000/WD-xmlschema-1-20000225/structures.dtd"-->
+    <!--
+        Castor Object Mapping XML Schema
+        
+        Namespace: http://castor.exolab.org/
+        System:    http://castor.exolab.org/mapping.xsd
+        Public:    -//EXOLAB/Castor Object Mapping Schema Version 1.0//EN
+        
+        *Note*: This schema is under evolution and subject to change.
+        
+    -->
+    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+        targetNamespace="http://castor.exolab.org/"
+        xmlns="http://castor.exolab.org/"
+        version="0.9.4">
+        
+        <xsd:element name="mapping">
+            <xsd:complexType>
+                <xsd:sequence>
+                    <xsd:element name="description"   type="xsd:string" minOccurs="0" maxOccurs="1" />
+                    <xsd:element ref="include"        minOccurs="0" maxOccurs="unbounded" />
+                    <xsd:element ref="class"          minOccurs="0" maxOccurs="unbounded" />
+                    <xsd:element ref="key-generator"  minOccurs="0" maxOccurs="unbounded" />
+                </xsd:sequence>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="include">
+            <xsd:complexType>
+                <xsd:attribute name="href" type="xsd:string" use="required"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="class">
+            <xsd:complexType>
+                <xsd:sequence>
+                    <xsd:element name="description" type="xsd:string" minOccurs="0" maxOccurs="1" />
+                    <xsd:element ref="cache-type"   minOccurs="0" maxOccurs="1" />
+                    <xsd:element ref="map-to" minOccurs="0" maxOccurs="1" />
+                    <xsd:choice minOccurs="1">
+                        <xsd:element ref="field" minOccurs="0" maxOccurs="unbounded"/>
+                        <xsd:element ref="container" minOccurs="0" maxOccurs="unbounded"/>
+                    </xsd:choice>
+                </xsd:sequence>
+                <xsd:attribute name="name"     type="xsd:ID"         use="required"/>
+                <xsd:attribute name="extends"  type="xsd:IDREF"      use="optional"/>
+                <xsd:attribute name="depends"  type="xsd:IDREF"      use="optional"/>
+                <xsd:attribute name="identity" type="xsd:NMTOKENS"   use="optional"/>
+                <xsd:attribute name="access"   default="shared"    use="optional">
+                    <xsd:simpleType>
+                        <xsd:restriction base="xsd:string">
+                            <xsd:enumeration value="read-only"/>
+                            <xsd:enumeration value="shared"/>
+                            <xsd:enumeration value="exclusive"/>
+                            <xsd:enumeration value="db-locked"/>
+                        </xsd:restriction>
+                    </xsd:simpleType>
+                </xsd:attribute>
+                <xsd:attribute name="key-generator" type="xsd:string"   use="optional"/>
+                <xsd:attribute name="auto-complete" type="xsd:boolean"  use="optional" default="false"/>
+                <xsd:attribute name="verify-constructable" type="xsd:boolean"  use="optional" default="true"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="map-to">
+            <xsd:complexType>
+                <xsd:attribute name="table"     type="xsd:NMTOKEN"  use="optional"/>
+                <xsd:attribute name="xml"       type="xsd:string"   use="optional"/>
+                <xsd:attribute name="ns-uri"    type="xsd:string"   use="optional"/>
+                <xsd:attribute name="ns-prefix" type="xsd:NMTOKEN"  use="optional"/>
+                <xsd:attribute name="ldap-dn"   type="xsd:string"   use="optional"/>
+                <xsd:attribute name="ldap-oc"   type="xsd:string"   use="optional"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="field">
+            <xsd:complexType>
+                <xsd:sequence>
+                    <xsd:element name="description"   type="xsd:string" minOccurs="0" maxOccurs="1" />
+                    <xsd:element ref="sql"            minOccurs="0" maxOccurs="1"/>
+                    <xsd:element ref="bind-xml"       minOccurs="0" maxOccurs="1"/>
+                    <xsd:element ref="ldap"           minOccurs="0" maxOccurs="1"/>
+                </xsd:sequence>
+                
+                <xsd:attribute name="name"          type="xsd:string" use="required"/>
+                <xsd:attribute name="type"          type="xsd:string" use="optional"/>
+                <xsd:attribute name="required"      type="xsd:boolean"  use="optional"   default="false"/>
+                <xsd:attribute name="transient"     type="xsd:boolean"  use="optional"   default="false"/>
+                <xsd:attribute name="direct"        type="xsd:boolean"  use="optional"   default="false"/>
+                <xsd:attribute name="lazy"          type="xsd:boolean"  use="optional"   default="false"/>
+                <xsd:attribute name="container"     type="xsd:boolean"  use="optional"/>
+                <xsd:attribute name="get-method"    type="xsd:string"  use="optional"/>
+                <xsd:attribute name="has-method"    type="xsd:string"  use="optional"/>
+                <xsd:attribute name="set-method"    type="xsd:string"  use="optional"/>
+                <xsd:attribute name="create-method" type="xsd:string"  use="optional"/>
+                <xsd:attribute name="handler"       type="xsd:string"   use="optional"/>
+                <xsd:attribute name="collection"    use="optional">
+                    <xsd:simpleType>
+                        <xsd:restriction base="xsd:string">
+                            <xsd:enumeration value="array"/>
+                            <xsd:enumeration value="vector"/>
+                            <xsd:enumeration value="arraylist"/>
+                            <xsd:enumeration value="hashtable"/>
+                            <xsd:enumeration value="collection"/>
+                            <xsd:enumeration value="set"/>
+                            <xsd:enumeration value="map"/>
+                            <xsd:enumeration value="enumerate"/>
+                        </xsd:restriction>
+                    </xsd:simpleType>
+                </xsd:attribute>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="container">
+            <xsd:complexType>
+                <xsd:sequence>
+                    <xsd:element name="description" type="xsd:string" minOccurs="0" maxOccurs="1" />
+                    <xsd:element ref="field" minOccurs="1"/>
+                </xsd:sequence>
+                <xsd:attribute name="name"          type="xsd:NMTOKEN" use="required"/>
+                <xsd:attribute name="type"          type="xsd:NMTOKEN" use="optional"/>
+                <xsd:attribute name="required"      type="xsd:boolean" use="optional"  default="false"/>
+                <xsd:attribute name="direct"        type="xsd:boolean" use="optional"  default="false"/>
+                <xsd:attribute name="get-method"    type="xsd:NMTOKEN" use="optional"/>
+                <xsd:attribute name="set-method"    type="xsd:NMTOKEN" use="optional"/>
+                <xsd:attribute name="create-method" type="xsd:NMTOKEN" use="optional"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="sql">
+            <xsd:complexType>
+                <xsd:attribute name="name"       type="xsd:NMTOKENS"   use="optional"/>
+                <xsd:attribute name="type"       type="xsd:string"   use="optional"/>
+                <xsd:attribute name="many-table" type="xsd:NMTOKEN"    use="optional"/>
+                <xsd:attribute name="many-key"   type="xsd:NMTOKENS"   use="optional"/>
+                <xsd:attribute name="read-only"  type="xsd:boolean"    use="optional" default="false"/>
+                
+                <!-- signals that this field is transient for database mapping (ie should be ignored) -->
+                <xsd:attribute name="transient" type="xsd:boolean" use="optional"/>
+                
+                
+                <xsd:attribute name="dirty"  default="check"  use="optional">
+                    <xsd:simpleType>
+                        <xsd:restriction base="xsd:string">
+                            <xsd:enumeration value="check"/>
+                            <xsd:enumeration value="ignore"/>
+                        </xsd:restriction>
+                    </xsd:simpleType>
+                </xsd:attribute>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <!--
+            The 'bind-xml' element is used for specifying XML specific databinding
+            properties and behavior for a specific field. 'bind-xml' may only appear
+            as a child of a 'field' element.
+        -->
+        <xsd:element name="bind-xml">
+            <xsd:annotation>
+                <xsd:documentation>
+                    The 'bind-xml' element is used for specifying XML specific databinding
+                    properties and behavior for a specific field. 'bind-xml' may only appear
+                    as a child of a 'field' element.
+                </xsd:documentation>
+            </xsd:annotation>
+            <xsd:complexType>
+                
+                <xsd:sequence>
+                    <xsd:element ref="class" minOccurs="0" maxOccurs="1"/>
+                    <xsd:element name="property" type="propertyType" minOccurs="0" maxOccurs="unbounded"/>
+                </xsd:sequence>
+                
+                <!--
+                    An optional attribute used for specifying the XML name for the
+                    field associated with the 'bind-xml' element.
+                -->
+                <xsd:attribute name="name" type="xsd:QName"  use="optional">
+                    <xsd:annotation>
+                        <xsd:documentation>
+                            An optional attribute used for specifying the XML name for the
+                            field associated with the 'bind-xml' element.
+                        </xsd:documentation>
+                    </xsd:annotation>
+                </xsd:attribute>
+                
+                <xsd:attribute name="type" type="xsd:NMTOKEN"  use="optional"/>
+                
+                <!--
+                    Allows specifying how Castor should automatically determines
+                    the XML name of this field when no name has been specified.
+                -->
+                <xsd:attribute name="auto-naming" use="optional">
+                    <xsd:annotation>
+                        <xsd:documentation>
+                            Allows specifying how Castor should automatically determines
+                            the XML name of this field when no name has been specified.
+                            In most cases the XML name is determined by using the field name,
+                            but in some cases the user may want to use the Class name of
+                            the field type. This attribute allows choosing between the
+                            two approaches. If this attribute is not specified, the field
+                            name is used as the XML name.
+                        </xsd:documentation>
+                    </xsd:annotation>
+                    <xsd:simpleType>
+                        <xsd:restriction base="xsd:string">
+                            <xsd:enumeration value="deriveByClass"/>
+                            <xsd:enumeration value="deriveByField"/>
+                        </xsd:restriction>
+                    </xsd:simpleType>
+                </xsd:attribute>
+                
+                <!--
+                    Allows specifying a nested location path for this field,
+                    the value should just be a simplified XPath like value
+                    where names are separated by "/".
+                -->
+                <xsd:attribute name="location" type="xsd:string" use="optional">
+                    <xsd:annotation>
+                        <xsd:documentation>
+                            Allows specifying a nested location path for this field,
+                            the value should just be a simplified XPath like value
+                            where names are separated by "/".
+                        </xsd:documentation>
+                    </xsd:annotation>
+                </xsd:attribute>
+                
+                <!-- Allows overriding the matching rule -->
+                <xsd:attribute name="matches" type="xsd:string" use="optional"/>
+                
+                
+                <!-- Signal that this field should be marshalled as a reference -->
+                <xsd:attribute name="reference" type="xsd:boolean" use="optional"/>
+                
+                <!-- NodeType for the XML node -->
+                <xsd:attribute name="node" use="optional">
+                    <xsd:simpleType>
+                        <xsd:restriction base="xsd:string">
+                            <xsd:enumeration value="attribute"/>
+                            <xsd:enumeration value="element"/>
+                            <xsd:enumeration value="namespace"/>
+                            <xsd:enumeration value="text"/>
+                        </xsd:restriction>
+                    </xsd:simpleType>
+                </xsd:attribute>
+                
+                <xsd:attribute name="QName-prefix" type="xsd:NMTOKEN" use="optional"/>
+                
+                <!-- Signal that this field is transient for XML (ie should be ignored) -->
+                <xsd:attribute name="transient" type="xsd:boolean" use="optional"/>
+                
+            </xsd:complexType>
+        </xsd:element>
+        
+        
+        
+        <xsd:element name="ldap">
+            <xsd:complexType>
+                <xsd:attribute name="name" type="xsd:NMTOKEN" use="optional"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="key-generator">
+            <xsd:complexType>
+                <xsd:sequence>
+                    <xsd:element ref="param" minOccurs="0" maxOccurs="unbounded" />
+                </xsd:sequence>
+                <xsd:attribute name="name"  type="xsd:ID"     use="required"/>
+                <xsd:attribute name="alias" type="xsd:string" use="optional"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="cache-type">
+            <xsd:complexType>
+                <xsd:attribute name="type" type="xsd:string" use="optional" default="count-limited" />
+                <xsd:attribute name="capacity" type="xsd:integer" use="optional"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        <xsd:element name="param">
+            <xsd:complexType>
+                <xsd:attribute name="name"  type="xsd:string"  use="required"/>
+                <xsd:attribute name="value" type="xsd:string"  use="required"/>
+            </xsd:complexType>
+        </xsd:element>
+        
+        
+        <xsd:complexType name="propertyType">
+            <xsd:sequence>
+                <xsd:element name="name"  type="xsd:string"/>
+                <xsd:element name="value" type="xsd:string"/>
+            </xsd:sequence>
+        </xsd:complexType>
+        
+        
+    </xsd:schema>