deegree 2.3 (2010/04/09 10:10 build-4-official)

org.deegree.io.datastore.schema
Class MappedFeatureType

java.lang.Object
  extended by org.deegree.model.feature.schema.DefaultFeatureType
      extended by org.deegree.io.datastore.schema.MappedFeatureType
All Implemented Interfaces:
Serializable, FeatureType

public class MappedFeatureType
extends DefaultFeatureType

Represents a FeatureType with mapping (persistence) information.

The mapping information describe how the FeatureType is mapped in the database backend.

Version:
$Revision: 18195 $, $Date: 2009-06-18 17:55:39 +0200 (Do, 18. Jun 2009) $
Author:
Markus Schneider , last edited by: $Author: mschneider $
See Also:
Serialized Form

Constructor Summary
MappedFeatureType(QualifiedName name, boolean isAbstract, PropertyType[] properties, String table, MappedGMLId gmlId, MappedGMLSchema schema, boolean isVisible, boolean isUpdatable, boolean isDeletable, boolean isInsertable, boolean isPseudoFeatureType, URI defaultSRS, URI[] otherSRS)
          Creates a new instance of MappedFeatureType from the given parameters.
 
Method Summary
 DatastoreTransaction acquireTransaction()
          Retrieves a transaction object for this feature type.
 FeatureId generateFid(DatastoreTransaction ta)
          Generates a new and unique feature identifier.
 MappedFeatureType[] getConcreteSubstitutions()
          Returns all non-abstract feature types that may be used as substitutions for this feature type.
 URI getDefaultSRS()
          Returns the default SRS.
 MappedGMLId getGMLId()
          Returns the mapping information for the "gml:Id" attribute.
 MappedGMLSchema getGMLSchema()
          Returns the GML Application schema that defines this feature type.
 URI[] getOtherSRS()
          Returns alternative SRS that may be used to query the feature type.
 String getTable()
          Returns the name of the (database) table where the feature type is stored.
 boolean hasSeveralImplementations()
          Return whether this feature type has more than one concrete substitution.
 boolean isDeletable()
          Returns whether delete operations may be performed on the persistent feature type.
 boolean isInsertable()
          Returns whether insert operations may be performed on the persistent feature type.
 boolean isPseudoFeatureType()
          Returns whether this feature type definition is used to store complex xml data that is not a real gml feature.
 boolean isUpdatable()
          Returns whether update operations may be performed on the persistent feature type.
 boolean isVisible()
          Returns whether the persistent feature type is visible (e.g. queryable in the WFS).
 FeatureCollection performQuery(Query query)
          Performs the given Query.
 FeatureCollection performQuery(Query query, DatastoreTransaction context)
          Performs the given Query inside the given transaction context.
 
Methods inherited from class org.deegree.model.feature.schema.DefaultFeatureType
equals, equals, getGeometryProperties, getName, getNameSpace, getProperties, getProperty, getProperty, getPropertyName, getSchemaLocation, isAbstract, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MappedFeatureType

MappedFeatureType(QualifiedName name,
                  boolean isAbstract,
                  PropertyType[] properties,
                  String table,
                  MappedGMLId gmlId,
                  MappedGMLSchema schema,
                  boolean isVisible,
                  boolean isUpdatable,
                  boolean isDeletable,
                  boolean isInsertable,
                  boolean isPseudoFeatureType,
                  URI defaultSRS,
                  URI[] otherSRS)
Creates a new instance of MappedFeatureType from the given parameters.

Parameters:
name -
isAbstract -
properties -
table -
gmlId -
schema -
isVisible -
isUpdatable -
isDeletable -
isInsertable -
isPseudoFeatureType -
otherSRS -
defaultSRS -
Method Detail

getTable

public String getTable()
Returns the name of the (database) table where the feature type is stored.

Returns:
name of the associated table

getGMLId

public MappedGMLId getGMLId()
Returns the mapping information for the "gml:Id" attribute.

Returns:
mapping information for the "gml:Id" attribute

generateFid

public FeatureId generateFid(DatastoreTransaction ta)
                      throws IdGenerationException
Generates a new and unique feature identifier.

Parameters:
ta -
Returns:
a new and unique feature identifier.
Throws:
IdGenerationException

getGMLSchema

public MappedGMLSchema getGMLSchema()
Returns the GML Application schema that defines this feature type.

Returns:
GML Application schema that defines this feature type

isVisible

public boolean isVisible()
Returns whether the persistent feature type is visible (e.g. queryable in the WFS).

Returns:
true, if the persistent feature type is visible.

isUpdatable

public boolean isUpdatable()
Returns whether update operations may be performed on the persistent feature type.

Returns:
true, if update operations may be performed, false otherwise.

isDeletable

public boolean isDeletable()
Returns whether delete operations may be performed on the persistent feature type.

Returns:
true, if delete operations may be performed, false otherwise.

isInsertable

public boolean isInsertable()
Returns whether insert operations may be performed on the persistent feature type.

Returns:
true, if insert operations may be performed, false otherwise.

isPseudoFeatureType

public boolean isPseudoFeatureType()
Returns whether this feature type definition is used to store complex xml data that is not a real gml feature.

If this is the case, the gml:id and gml:boundedBy elements are omitted in XML output.

Returns:
true, if this feature type declaration is a pseudo feature type, false otherwise

getDefaultSRS

public URI getDefaultSRS()
Returns the default SRS.

Returns:
the default SRS

getOtherSRS

public URI[] getOtherSRS()
Returns alternative SRS that may be used to query the feature type.

Returns:
alternative SRS

performQuery

public FeatureCollection performQuery(Query query)
                               throws DatastoreException,
                                      UnknownCRSException
Performs the given Query. It must target solely this MappedFeatureType (joins are not allowed).

All members of the resulting FeatureCollection have this MappedFeatureType.

Parameters:
query - Query to be performed
Returns:
FeatureCollection with members that have this type
Throws:
DatastoreException
UnknownCRSException

performQuery

public FeatureCollection performQuery(Query query,
                                      DatastoreTransaction context)
                               throws DatastoreException,
                                      UnknownCRSException
Performs the given Query inside the given transaction context. It must target solely this MappedFeatureType (joins are not allowed).

All members of the resulting FeatureCollection have this MappedFeatureType.

Parameters:
query - Query to be performed
context - transaction context (used to specify the JDBCConnection, for example)
Returns:
FeatureCollection with members that have this type
Throws:
DatastoreException
UnknownCRSException

acquireTransaction

public DatastoreTransaction acquireTransaction()
                                        throws DatastoreException
Retrieves a transaction object for this feature type.

Returns:
a transaction object for this feature type
Throws:
DatastoreException - if transaction could not be acquired

getConcreteSubstitutions

public MappedFeatureType[] getConcreteSubstitutions()
Returns all non-abstract feature types that may be used as substitutions for this feature type.

Returns:
all non-abstract feature types that may be used as substitutions

hasSeveralImplementations

public boolean hasSeveralImplementations()
Return whether this feature type has more than one concrete substitution.

Read as: Is there only one concrete feature type that all instances of this type must have? Or are there several possible concrete subtypes?

Returns:
true, if the feature type has more than once concrete implementations, false otherwise

deegree 2.3 (2010/04/09 10:10 build-4-official)

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org