org.vfny.geoserver.requests.wfs
Class FeatureRequest

java.lang.Object
  extended byorg.vfny.geoserver.requests.Request
      extended byorg.vfny.geoserver.requests.WFSRequest
          extended byorg.vfny.geoserver.requests.wfs.FeatureRequest
Direct Known Subclasses:
FeatureWithLockRequest

public class FeatureRequest
extends WFSRequest

Implements the WFS GetFeature interface, which responds to requests for GML. This servlet accepts a getFeatures request and returns GML2.0 structured XML docs. It is made up of the standard request params, plus one or more Query objects, plus a user-assigned handle. There are also params for feature versioning and alternate formats, but GeoServer does not yet support those.


Field Summary
protected  java.lang.String featureVersion
          Creates an object version type
protected  java.lang.String handle
          Specifices the user-defined name for the entire get feature request
protected  int maxFeatures
          Creates a max features constraint for the entire request
protected  java.lang.String outputFormat
          Specifies the output format
protected  java.util.List queries
          Creates a full list of queries
 
Fields inherited from class org.vfny.geoserver.requests.WFSRequest
WFS_SERVICE_TYPE
 
Fields inherited from class org.vfny.geoserver.requests.Request
httpServletRequest, request, service, version
 
Constructor Summary
FeatureRequest()
          Empty constructor.
 
Method Summary
 void addQuery(Query query)
          Returns a specific query from this GetFeature request.
 boolean equals(java.lang.Object obj)
          DOCUMENT ME!
 java.lang.String getFeatureVersion()
          Returns the version for the entire GetFeature request.
 java.lang.String getHandle()
          Returns the user-defined name for the entire GetFeature request.
 int getMaxFeatures()
          Returns the maximum number of features for this request.
 java.lang.String getOutputFormat()
          Gets the output format for this GetFeature request.
 java.util.List getQueries()
          Returns the entire set of queries for this GetFeature request.
 Query getQuery(int i)
          Returns a specific query from this GetFeature request.
 int getQueryCount()
          Returns the number of queries for this GetFeature request.
 int hashCode()
          DOCUMENT ME!
 void setFeatureVersion(java.lang.String version)
          Returns the version for the entire GetFeature request.
 void setHandle(java.lang.String handle)
          Sets the user-defined name for this request.
 void setMaxFeatures(int maxFeatures)
          Sets the maximum number of features this request should return.
 void setMaxFeatures(java.lang.String maxFeatures)
          Parses the GetFeature reqeust and returns a contentHandler.
 void setOutputFormat(java.lang.String outputFormat)
          Sets the output format for this GetFeature request.
 void setQueries(java.util.List queries)
          Sets the entire set of queries for this GetFeature request.
 java.lang.String toString()
          Standard override of toString()
 
Methods inherited from class org.vfny.geoserver.requests.Request
getBaseUrl, getGeoServer, getHttpServletRequest, getRequest, getRootDir, getService, getValidationProcessor, getVersion, isLoggedIn, setHttpServletRequest, setRequest, setService, setVersion
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

maxFeatures

protected int maxFeatures
Creates a max features constraint for the entire request


outputFormat

protected java.lang.String outputFormat
Specifies the output format


handle

protected java.lang.String handle
Specifices the user-defined name for the entire get feature request


featureVersion

protected java.lang.String featureVersion
Creates an object version type


queries

protected java.util.List queries
Creates a full list of queries

Constructor Detail

FeatureRequest

public FeatureRequest()
Empty constructor.

Method Detail

setQueries

public void setQueries(java.util.List queries)
Sets the entire set of queries for this GetFeature request.

Parameters:
queries - The Querys of this request.

addQuery

public void addQuery(Query query)
Returns a specific query from this GetFeature request.

Parameters:
query - a Query to add to this request.

getQueries

public java.util.List getQueries()
Returns the entire set of queries for this GetFeature request.

Returns:
The List of Query objects for this request.

getQueryCount

public int getQueryCount()
Returns the number of queries for this GetFeature request.

Returns:
The number of queries held by this request.

getQuery

public Query getQuery(int i)
Returns a specific query from this GetFeature request.

Parameters:
i - The index of the query to retrieve.
Returns:
The query at position i.

setOutputFormat

public void setOutputFormat(java.lang.String outputFormat)
Sets the output format for this GetFeature request.

Parameters:
outputFormat - only gml2 is currently supported.

getOutputFormat

public java.lang.String getOutputFormat()
Gets the output format for this GetFeature request.

Returns:
"GML2"

setHandle

public void setHandle(java.lang.String handle)
Sets the user-defined name for this request.

Parameters:
handle - The string to be used in reporting errors.

getHandle

public java.lang.String getHandle()
Returns the user-defined name for the entire GetFeature request.

Returns:
The string to use in error reporting with this request.

setFeatureVersion

public void setFeatureVersion(java.lang.String version)
Returns the version for the entire GetFeature request. Not currently used in GeoServer.

Parameters:
version - The version of the feature to retrieve.

getFeatureVersion

public java.lang.String getFeatureVersion()
Returns the version for the entire GetFeature request. Not currently used in GeoServer.

Returns:
The version of the feature to retrieve.

setMaxFeatures

public void setMaxFeatures(int maxFeatures)
Sets the maximum number of features this request should return.

Parameters:
maxFeatures - The maximum number of features to return.

setMaxFeatures

public void setMaxFeatures(java.lang.String maxFeatures)
Parses the GetFeature reqeust and returns a contentHandler.

Parameters:
maxFeatures - The maximum number of features to return.

getMaxFeatures

public int getMaxFeatures()
Returns the maximum number of features for this request.

Returns:
Maximum number of features this request will return.

toString

public java.lang.String toString()
Standard override of toString()

Returns:
a String representation of this request.

equals

public boolean equals(java.lang.Object obj)
DOCUMENT ME!

Overrides:
equals in class Request
Parameters:
obj - DOCUMENT ME!
Returns:
DOCUMENT ME!

hashCode

public int hashCode()
DOCUMENT ME!

Overrides:
hashCode in class Request
Returns:
DOCUMENT ME!