org.deegree.services.wfs
Class WFSFeatureStoreManager

java.lang.Object
  extended by org.deegree.services.wfs.WFSFeatureStoreManager

public class WFSFeatureStoreManager
extends Object

Manages the FeatureStore instances for the WebFeatureService.

Version:
$Revision: $, $Date: $
Author:
Markus Schneider, last edited by: $Author: schneider $
See Also:
WebFeatureService

Constructor Summary
WFSFeatureStoreManager()
           
 
Method Summary
 void addStore(FeatureStore fs)
          Registers a new FeatureStore to the WFS.
 QName[] getFeatureTypeNames()
          Returns the qualified names of all served FeatureTypes.
 Collection<FeatureType> getFeatureTypes()
          Returns all FeatureTypes.
 Map<String,String> getPrefixToNs()
          Get the prefix-to-namespace map that is constructed from the NamespaceHints in the configuration
 FeatureStore getStore(QName ftName)
          Returns the FeatureStore instance which is responsible for the specified feature type.
 FeatureStore[] getStores()
          Returns all registered FeatureStore instances.
 Map<String,String> getTargetNsToPrefix()
          Get the namespace-to-prefix bindings for the namespaces of the application schemas.
 void init(DeegreeWFS sc, String baseURL, DeegreeWorkspace workspace)
           
 FeatureType lookupFeatureType(QName ftName)
          Looks up the FeatureType with the given qualified name (in a namespace-tolerant manner).
 void removeStore(FeatureStore fs)
          Deregisters the specified FeatureStore from the WFS.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WFSFeatureStoreManager

public WFSFeatureStoreManager()
Method Detail

init

public void init(DeegreeWFS sc,
                 String baseURL,
                 DeegreeWorkspace workspace)
          throws ResourceInitException
Parameters:
sc -
baseURL -
Throws:
FeatureStoreException
ResourceInitException

getFeatureTypeNames

public QName[] getFeatureTypeNames()
Returns the qualified names of all served FeatureTypes.

Returns:
the qualified names, never null

getFeatureTypes

public Collection<FeatureType> getFeatureTypes()
Returns all FeatureTypes.

Returns:
served feature types, may be empty, but never null

lookupFeatureType

public FeatureType lookupFeatureType(QName ftName)
Looks up the FeatureType with the given qualified name (in a namespace-tolerant manner).

This method is tolerant to improve interoperability with clients (especially WFS 1.0.0) that only provide the local name or the prefixed name without a namespace binding.

Parameters:
ftName - feature type to look up, must not be null
Returns:
feature type with the given name, or null if no such feature type is served

getStore

public FeatureStore getStore(QName ftName)
Returns the FeatureStore instance which is responsible for the specified feature type.

Parameters:
ftName - name of the FeatureType
Returns:
the responsible FeatureStore or null if no such store exists, i.e. the specified feature type is not served

getPrefixToNs

public Map<String,String> getPrefixToNs()
Get the prefix-to-namespace map that is constructed from the NamespaceHints in the configuration

Returns:
the prefix-to-namespace map

getTargetNsToPrefix

public Map<String,String> getTargetNsToPrefix()
Get the namespace-to-prefix bindings for the namespaces of the application schemas.

Returns:
the namespace-to-prefix map

getStores

public FeatureStore[] getStores()
Returns all registered FeatureStore instances.

Returns:
all registered feature stores

addStore

public void addStore(FeatureStore fs)
Registers a new FeatureStore to the WFS.

Parameters:
fs - store to be registered

removeStore

public void removeStore(FeatureStore fs)
Deregisters the specified FeatureStore from the WFS.

Parameters:
fs - store to be registered


Copyright © 2011. All Rights Reserved.