/*
* GeoTools - The Open Source Java GIS Toolkit
* http://geotools.org
*
* (C) 2002-2008, Open Source Geospatial Foundation (OSGeo)
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License.
*
* This library 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
* Lesser General Public License for more details.
*/
package org.geotools.gml2;
import java.util.ArrayList;
import java.util.Collections;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;
import org.geotools.feature.NameImpl;
import org.geotools.feature.type.AttributeDescriptorImpl;
import org.geotools.feature.type.AttributeTypeImpl;
import org.geotools.feature.type.FeatureTypeImpl;
import org.geotools.feature.type.ProfileImpl;
import org.geotools.feature.type.SchemaImpl;
import org.geotools.gml2.GML;
import org.geotools.xs.XSSchema;
import org.opengis.feature.Feature;
import org.opengis.feature.type.AttributeType;
import org.opengis.feature.type.FeatureType;
import org.opengis.feature.type.Name;
import com.vividsolutions.jts.geom.Coordinate;
import com.vividsolutions.jts.geom.CoordinateSequence;
import com.vividsolutions.jts.geom.Envelope;
import com.vividsolutions.jts.geom.Geometry;
import com.vividsolutions.jts.geom.GeometryCollection;
import com.vividsolutions.jts.geom.LineString;
import com.vividsolutions.jts.geom.LinearRing;
import com.vividsolutions.jts.geom.MultiLineString;
import com.vividsolutions.jts.geom.MultiPoint;
import com.vividsolutions.jts.geom.MultiPolygon;
import com.vividsolutions.jts.geom.Point;
import com.vividsolutions.jts.geom.Polygon;
public class GMLSchema extends SchemaImpl {
/**
* <p>
* <pre>
* <code>
* <complexType abstract="true" name="AbstractGeometryType">
* <annotation>
* <documentation>
* All geometry elements are derived from this abstract supertype;
* a geometry element may have an identifying attribute (gid).
* It may be associated with a spatial reference system.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="anyType">
* <attribute name="gid" type="ID" use="optional"/>
* <attribute name="srsName" type="anyURI" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType ABSTRACTGEOMETRYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "AbstractGeometryType"), Geometry.class, false, true,
Collections.EMPTY_LIST, XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType abstract="true" name="AbstractGeometryCollectionBaseType">
* <annotation>
* <documentation>
* This abstract base type for geometry collections just makes the
* srsName attribute mandatory.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:AbstractGeometryType">
* <attribute name="gid" type="ID" use="optional"/>
* <attribute name="srsName" type="anyURI" use="required"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType ABSTRACTGEOMETRYCOLLECTIONBASETYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "AbstractGeometryCollectionBaseType"),
GeometryCollection.class, false, true, Collections.EMPTY_LIST,
ABSTRACTGEOMETRYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="GeometryAssociationType">
* <annotation>
* <documentation>
* An instance of this type (e.g. a geometryMember) can either
* enclose or point to a primitive geometry element. When serving
* as a simple link that references a remote geometry instance,
* the value of the gml:remoteSchema attribute can be used to
* locate a schema fragment that constrains the target instance.
* </documentation>
* </annotation>
* <sequence minOccurs="0">
* <element ref="gml:_Geometry"/>
* </sequence>optional
*
* <!-- <attributeGroup ref="gml:AssociationAttributeGroup"/> -->
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType GEOMETRYASSOCIATIONTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "GeometryAssociationType"), Geometry.class, false,
false, Collections.EMPTY_LIST, XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="GeometryCollectionType">
* <annotation>
* <documentation>
* A geometry collection must include one or more geometries, referenced
* through geometryMember elements. User-defined geometry collections
* that accept GML geometry classes as members must instantiate--or
* derive from--this type.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractGeometryCollectionBaseType">
* <sequence>
* <element maxOccurs="unbounded" ref="gml:geometryMember"/>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType GEOMETRYCOLLECTIONTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "GeometryCollectionType"), GeometryCollection.class,
false, false, Collections.EMPTY_LIST, ABSTRACTGEOMETRYCOLLECTIONBASETYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="CoordType">
* <annotation>
* <documentation>
* Represents a coordinate tuple in one, two, or three dimensions.
* </documentation>
* </annotation>
* <sequence>
* <element name="X" type="decimal"/>
* <element minOccurs="0" name="Y" type="decimal"/>
* <element minOccurs="0" name="Z" type="decimal"/>
* </sequence>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType COORDTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "CoordType"), Coordinate.class, false, false,
Collections.EMPTY_LIST, XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="CoordinatesType">
* <annotation>
* <documentation>
* Coordinates can be included in a single string, but there is no
* facility for validating string content. The value of the 'cs' attribute
* is the separator for coordinate values, and the value of the 'ts'
* attribute gives the tuple separator (a single space by default); the
* default values may be changed to reflect local usage.
* </documentation>
* </annotation>
* <simpleContent>
* <extension base="string">
* <attribute default="." name="decimal" type="string" use="optional"/>
* <attribute default="," name="cs" type="string" use="optional"/>
* <attribute default=" " name="ts" type="string" use="optional"/>
* </extension>
* </simpleContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType COORDINATESTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "CoordinatesType"), CoordinateSequence.class, false,
false, Collections.EMPTY_LIST, XSSchema.STRING_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="LinearRingType">
* <annotation>
* <documentation>
* A LinearRing is defined by four or more coordinate tuples, with
* linear interpolation between them; the first and last coordinates
* must be coincident.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractGeometryType">
* <sequence>
* <choice>
* <element maxOccurs="unbounded" minOccurs="4" ref="gml:coord"/>
* <element ref="gml:coordinates"/>
* </choice>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType LINEARRINGTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "LinearRingType"), LinearRing.class, false, false,
Collections.EMPTY_LIST, ABSTRACTGEOMETRYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="LinearRingMemberType">
* <annotation>
* <documentation>Restricts the outer or inner boundary of a polygon instance
* to being a LinearRing.</documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:LinearRing"/>
* </sequence>
* <attributeGroup ref="gml:AssociationAttributeGroup"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType LINEARRINGMEMBERTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "LinearRingMemberType"), LinearRing.class, false,
false, Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="PolygonType">
* <annotation>
* <documentation>
* A Polygon is defined by an outer boundary and zero or more inner
* boundaries which are in turn defined by LinearRings.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractGeometryType">
* <sequence>
* <element ref="gml:outerBoundaryIs"/>
* <element maxOccurs="unbounded" minOccurs="0" ref="gml:innerBoundaryIs"/>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType POLYGONTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "PolygonType"), Polygon.class, false, false,
Collections.EMPTY_LIST, ABSTRACTGEOMETRYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="PolygonMemberType">
* <annotation>
* <documentation>Restricts the geometry member to being a Polygon instance.</documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:Polygon"/>
* </sequence>
* <attributeGroup ref="gml:AssociationAttributeGroup"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType POLYGONMEMBERTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "PolygonMemberType"), Polygon.class, false, false,
Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiPolygonType">
* <annotation>
* <documentation>
* A MultiPolygon is defined by one or more Polygons, referenced through
* polygonMember elements.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryCollectionType">
* <sequence>
* <element maxOccurs="unbounded" ref="gml:polygonMember"/>
* </sequence>
* <attribute name="gid" type="ID" use="optional"/>
* <attribute name="srsName" type="anyURI" use="required"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTIPOLYGONTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiPolygonType"), MultiPolygon.class, false,
false, Collections.EMPTY_LIST, GEOMETRYCOLLECTIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiPolygonPropertyType">
* <annotation>
* <documentation>
* Encapsulates a MultiPolygon to represent the following discontiguous
* geometric properties: multiCoverage, multiExtentOf.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:MultiPolygon"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTIPOLYGONPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiPolygonPropertyType"), MultiPolygon.class,
false, false, Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiGeometryPropertyType">
* <annotation>
* <documentation>Encapsulates a MultiGeometry element.</documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:MultiGeometry"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTIGEOMETRYPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiGeometryPropertyType"), MultiPolygon.class,
false, false, Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="LineStringType">
* <annotation>
* <documentation>
* A LineString is defined by two or more coordinate tuples, with
* linear interpolation between them.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractGeometryType">
* <sequence>
* <choice>
* <element maxOccurs="unbounded" minOccurs="2" ref="gml:coord"/>
* <element ref="gml:coordinates"/>
* </choice>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType LINESTRINGTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "LineStringType"), LineString.class, false, false,
Collections.EMPTY_LIST, ABSTRACTGEOMETRYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="LineStringMemberType">
* <annotation>
* <documentation>Restricts the geometry member to being a LineString instance.</documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:LineString"/>
* </sequence>
* <attributeGroup ref="gml:AssociationAttributeGroup"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType LINESTRINGMEMBERTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "LineStringMemberType"), LineString.class, false,
false, Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiLineStringType">
* <annotation>
* <documentation>
* A MultiLineString is defined by one or more LineStrings, referenced
* through lineStringMember elements.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryCollectionType">
* <sequence>
* <element maxOccurs="unbounded" ref="gml:lineStringMember"/>
* </sequence>
* <attribute name="gid" type="ID" use="optional"/>
* <attribute name="srsName" type="anyURI" use="required"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTILINESTRINGTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiLineStringType"), MultiLineString.class, false,
false, Collections.EMPTY_LIST, GEOMETRYCOLLECTIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiLineStringPropertyType">
* <annotation>
* <documentation>
* Encapsulates a MultiLineString element to represent the following
* discontiguous geometric properties: multiEdgeOf, multiCenterLineOf.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:MultiLineString"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTILINESTRINGPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiLineStringPropertyType"),
MultiLineString.class, false, false, Collections.EMPTY_LIST,
GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="BoxType">
* <annotation>
* <documentation>
* The Box structure defines an extent using a pair of coordinate tuples.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractGeometryType">
* <sequence>
* <choice>
* <element maxOccurs="2" minOccurs="2" ref="gml:coord"/>
* <element ref="gml:coordinates"/>
* </choice>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType BOXTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "BoxType"), Envelope.class, false, false,
Collections.EMPTY_LIST, ABSTRACTGEOMETRYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <simpleType name="NullType">
* <annotation>
* <documentation>
* If a bounding shape is not provided for a feature collection,
* explain why. Allowable values are:
* innapplicable - the features do not have geometry
* unknown - the boundingBox cannot be computed
* unavailable - there may be a boundingBox but it is not divulged
* missing - there are no features
* </documentation>
* </annotation>
* <restriction base="string">
* <enumeration value="inapplicable"/>
* <enumeration value="unknown"/>
* <enumeration value="unavailable"/>
* <enumeration value="missing"/>
* </restriction>
* </simpleType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType NULLTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "NullType"), java.lang.Object.class, false, false,
Collections.EMPTY_LIST, XSSchema.STRING_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="BoundingShapeType">
* <annotation>
* <documentation>
* Bounding shapes--a Box or a null element are currently allowed.
* </documentation>
* </annotation>
* <sequence>
* <choice>
* <element ref="gml:Box"/>
* <element name="null" type="gml:NullType"/>
* </choice>
* </sequence>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType BOUNDINGSHAPETYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "BoundingShapeType"), Envelope.class, false, false,
Collections.EMPTY_LIST, XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType abstract="true" name="AbstractFeatureType">
* <annotation>
* <documentation>
* An abstract feature provides a set of common properties. A concrete
* feature type must derive from this type and specify additional
* properties in an application schema. A feature may optionally
* possess an identifying attribute ('fid').
* </documentation>
* </annotation>
* <sequence>
* <element minOccurs="0" ref="gml:description"/>
* <element minOccurs="0" ref="gml:name"/>
* <element minOccurs="0" ref="gml:boundedBy"/>
* <!-- additional properties must be specified in an application schema -->
* </sequence>
* <attribute name="fid" type="ID" use="optional"/>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
private static List ABSTRACTFEATURETYPE_TYPE_schema = new ArrayList();
static {
ABSTRACTFEATURETYPE_TYPE_schema.add(new AttributeDescriptorImpl(XSSchema.STRING_TYPE,
new NameImpl("http://www.opengis.net/gml", "description"), 1, 1, false, null));
ABSTRACTFEATURETYPE_TYPE_schema.add(new AttributeDescriptorImpl(XSSchema.STRING_TYPE,
new NameImpl("http://www.opengis.net/gml", "name"), 1, 1, false, null));
ABSTRACTFEATURETYPE_TYPE_schema.add(new AttributeDescriptorImpl(BOUNDINGSHAPETYPE_TYPE,
new NameImpl("http://www.opengis.net/gml", "boundedBy"), 1, 1, false, null));
}
public static final FeatureType ABSTRACTFEATURETYPE_TYPE = new FeatureTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "AbstractFeatureType"),
ABSTRACTFEATURETYPE_TYPE_schema, null, true, Collections.EMPTY_LIST,
XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType abstract="true" name="AbstractFeatureCollectionBaseType">
* <annotation>
* <documentation>
* This abstract base type just makes the boundedBy element mandatory
* for a feature collection.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:AbstractFeatureType">
* <sequence>
* <element minOccurs="0" ref="gml:description"/>
* <element minOccurs="0" ref="gml:name"/>
* <element ref="gml:boundedBy"/>
* </sequence>
* <attribute name="fid" type="ID" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
private static List ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE_schema = new ArrayList();
static {
ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE_schema.add(new AttributeDescriptorImpl(
XSSchema.STRING_TYPE, new NameImpl("http://www.opengis.net/gml", "description"), 1, 1,
false, null));
ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE_schema.add(new AttributeDescriptorImpl(
XSSchema.STRING_TYPE, new NameImpl("http://www.opengis.net/gml", "name"), 1, 1, false,
null));
ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE_schema.add(new AttributeDescriptorImpl(
BOUNDINGSHAPETYPE_TYPE, new NameImpl("http://www.opengis.net/gml", "boundedBy"), 1, 1,
false, null));
}
public static final FeatureType ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE = new FeatureTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "AbstractFeatureCollectionBaseType"),
ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE_schema, null, true, Collections.EMPTY_LIST,
ABSTRACTFEATURETYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="FeatureAssociationType">
* <annotation>
* <documentation>
* An instance of this type (e.g. a featureMember) can either
* enclose or point to a feature (or feature collection); this
* type can be restricted in an application schema to allow only
* specified features as valid participants in the association.
* When serving as a simple link that references a remote feature
* instance, the value of the gml:remoteSchema attribute can be
* used to locate a schema fragment that constrains the target
* instance.
* </documentation>
* </annotation>
* <sequence minOccurs="0">
* <element ref="gml:_Feature"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType FEATUREASSOCIATIONTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "FeatureAssociationType"), Feature.class, false,
false, Collections.EMPTY_LIST, XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType abstract="true" name="AbstractFeatureCollectionType">
* <annotation>
* <documentation>
* A feature collection contains zero or more featureMember elements.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractFeatureCollectionBaseType">
* <sequence>
* <element maxOccurs="unbounded" minOccurs="0" ref="gml:featureMember"/>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
private static List ABSTRACTFEATURECOLLECTIONTYPE_TYPE_schema = new ArrayList();
static {
ABSTRACTFEATURECOLLECTIONTYPE_TYPE_schema.add(new AttributeDescriptorImpl(
XSSchema.STRING_TYPE, new NameImpl("http://www.opengis.net/gml", "description"), 1, 1,
false, null));
ABSTRACTFEATURECOLLECTIONTYPE_TYPE_schema.add(new AttributeDescriptorImpl(
XSSchema.STRING_TYPE, new NameImpl("http://www.opengis.net/gml", "name"), 1, 1, false,
null));
ABSTRACTFEATURECOLLECTIONTYPE_TYPE_schema.add(new AttributeDescriptorImpl(
BOUNDINGSHAPETYPE_TYPE, new NameImpl("http://www.opengis.net/gml", "boundedBy"), 1, 1,
false, null));
ABSTRACTFEATURECOLLECTIONTYPE_TYPE_schema.add(new AttributeDescriptorImpl(
FEATUREASSOCIATIONTYPE_TYPE,
new NameImpl("http://www.opengis.net/gml", "featureMember"), 1, 1, false, null));
}
public static final FeatureType ABSTRACTFEATURECOLLECTIONTYPE_TYPE = new FeatureTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "AbstractFeatureCollectionType"),
ABSTRACTFEATURECOLLECTIONTYPE_TYPE_schema, null, true, Collections.EMPTY_LIST,
ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="GeometryPropertyType">
* <annotation>
* <documentation>
* A simple geometry property encapsulates a geometry element.
* Alternatively, it can function as a pointer (simple-type link)
* that refers to a remote geometry element.
* </documentation>
* </annotation>
* <sequence minOccurs="0">
* <element ref="gml:_Geometry"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType GEOMETRYPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "GeometryPropertyType"), Geometry.class, false,
false, Collections.EMPTY_LIST, XSSchema.ANYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="PolygonPropertyType">
* <annotation>
* <documentation>
* Encapsulates a single polygon to represent coverage or extentOf
* properties.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:Polygon"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType POLYGONPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "PolygonPropertyType"), Polygon.class, false, false,
Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="PointType">
* <annotation>
* <documentation>
* A Point is defined by a single coordinate tuple.
* </documentation>
* </annotation>
* <complexContent>
* <extension base="gml:AbstractGeometryType">
* <sequence>
* <choice>
* <element ref="gml:coord"/>
* <element ref="gml:coordinates"/>
* </choice>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType POINTTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "PointType"), Point.class, false, false,
Collections.EMPTY_LIST, ABSTRACTGEOMETRYTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="PointPropertyType">
* <annotation>
* <documentation>
* Encapsulates a single point to represent position, location, or
* centerOf properties.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:Point"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType POINTPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "PointPropertyType"), Point.class, false, false,
Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="PointMemberType">
* <annotation>
* <documentation>Restricts the geometry member to being a Point instance.</documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:Point"/>
* </sequence>
* <attributeGroup ref="gml:AssociationAttributeGroup"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType POINTMEMBERTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "PointMemberType"), Point.class, false, false,
Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiPointType">
* <annotation>
* <documentation>
* A MultiPoint is defined by one or more Points, referenced through
* pointMember elements.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryCollectionType">
* <sequence>
* <element maxOccurs="unbounded" ref="gml:pointMember"/>
* </sequence>
* <attribute name="gid" type="ID" use="optional"/>
* <attribute name="srsName" type="anyURI" use="required"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTIPOINTTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiPointType"), MultiPoint.class, false, false,
Collections.EMPTY_LIST, GEOMETRYCOLLECTIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="MultiPointPropertyType">
* <annotation>
* <documentation>
* Encapsulates a MultiPoint element to represent the following
* discontiguous geometric properties: multiLocation, multiPosition,
* multiCenterOf.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:MultiPoint"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType MULTIPOINTPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "MultiPointPropertyType"), MultiPoint.class, false,
false, Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
/**
* <p>
* <pre>
* <code>
* <complexType name="LineStringPropertyType">
* <annotation>
* <documentation>
* Encapsulates a single LineString to represent centerLineOf or
* edgeOf properties.
* </documentation>
* </annotation>
* <complexContent>
* <restriction base="gml:GeometryAssociationType">
* <sequence minOccurs="0">
* <element ref="gml:LineString"/>
* </sequence>
* <attributeGroup ref="xlink:simpleLink"/>
* <attribute ref="gml:remoteSchema" use="optional"/>
* </restriction>
* </complexContent>
* </complexType>
*
* </code>
* </pre>
* </p>
*
* @generated
*/
public static final AttributeType LINESTRINGPROPERTYTYPE_TYPE = new AttributeTypeImpl(new NameImpl(
"http://www.opengis.net/gml", "LineStringPropertyType"), LineString.class, false,
false, Collections.EMPTY_LIST, GEOMETRYASSOCIATIONTYPE_TYPE, null);
public GMLSchema() {
super("http://www.opengis.net/gml");
put(new NameImpl("http://www.opengis.net/gml", "AbstractGeometryType"),
ABSTRACTGEOMETRYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "AbstractGeometryCollectionBaseType"),
ABSTRACTGEOMETRYCOLLECTIONBASETYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "GeometryAssociationType"),
GEOMETRYASSOCIATIONTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "GeometryCollectionType"),
GEOMETRYCOLLECTIONTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "CoordType"), COORDTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "CoordinatesType"), COORDINATESTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "LinearRingType"), LINEARRINGTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "LinearRingMemberType"),
LINEARRINGMEMBERTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "PolygonType"), POLYGONTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "PolygonMemberType"), POLYGONMEMBERTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiPolygonType"), MULTIPOLYGONTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiPolygonPropertyType"),
MULTIPOLYGONPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiGeometryPropertyType"),
MULTIGEOMETRYPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "LineStringType"), LINESTRINGTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "LineStringMemberType"),
LINESTRINGMEMBERTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiLineStringType"), MULTILINESTRINGTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiLineStringPropertyType"),
MULTILINESTRINGPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "BoxType"), BOXTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "NullType"), NULLTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "BoundingShapeType"), BOUNDINGSHAPETYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "AbstractFeatureType"), ABSTRACTFEATURETYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "AbstractFeatureCollectionBaseType"),
ABSTRACTFEATURECOLLECTIONBASETYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "FeatureAssociationType"),
FEATUREASSOCIATIONTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "AbstractFeatureCollectionType"),
ABSTRACTFEATURECOLLECTIONTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "GeometryPropertyType"),
GEOMETRYPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "PolygonPropertyType"), POLYGONPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "PointType"), POINTTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "PointPropertyType"), POINTPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "PointMemberType"), POINTMEMBERTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiPointType"), MULTIPOINTTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "MultiPointPropertyType"),
MULTIPOINTPROPERTYTYPE_TYPE);
put(new NameImpl("http://www.opengis.net/gml", "LineStringPropertyType"),
LINESTRINGPROPERTYTYPE_TYPE);
}
/**
* Profile of GMLSchema capturing a unique mapping of Java classes.
* <p>
* This profile mostly matches to JTS Geometry classes.
*
* @return Subset of GMLSchema capturing a unique mapping of Java classes
*/
public ProfileImpl profile() {
Set<Name> profile = new LinkedHashSet<Name>();
profile.add(new NameImpl(GML.PointPropertyType));
profile.add(new NameImpl(GML.MultiPointPropertyType));
profile.add(new NameImpl(GML.LineStringPropertyType));
profile.add(new NameImpl(GML.MultiLineStringPropertyType));
profile.add(new NameImpl(GML.PolygonPropertyType));
profile.add(new NameImpl(GML.MultiPolygonPropertyType));
profile.add(new NameImpl(GML.GeometryPropertyType));
return new ProfileImpl(this,profile);
}
}