|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.deegree.crs.configuration.CRSConfiguration
public class CRSConfiguration
The CRSConfiguration
creates, instantiates and supplies a configured CRS-Provider. Because only one
crs-configuration is needed inside the JVM, this implementation uses a singleton pattern.
The configuration will try to read the file: crs_providers.properties. It uses following strategie to load this file, first the root directory (e.g. '/' or WEB-INF/classes ) will be searched. If no file was found there, it will try to load from the package. The properties file must denote a property with name 'CRS_PROVIDER' followed by a '=' and a fully qualified name denoting the class (an instance of CRSProvider) which should be available in the classpath. This class must have an empty constructor.
Field Summary | |
---|---|
static java.util.Map<java.lang.String,CRSConfiguration> |
DEFINED_CONFIGURATIONS
public so servlets can clear it, to avoid memory leaks... |
Method Summary | |
---|---|
static CRSConfiguration |
getCRSConfiguration()
Creates or returns an instance of the CRSConfiguration by reading the DEFAULT property configured in the 'crs_providers.properties'. |
static CRSConfiguration |
getCRSConfiguration(java.lang.String providerName)
Creates or returns an instance of the CRSConfiguration by trying to instantiate the given provider class. |
CRSProvider |
getProvider()
|
static void |
main(java.lang.String[] args)
export the given file to the deegree-crs format. |
static java.lang.String |
setDefaultFileProperty(java.lang.String fileName)
Overwrites the crs.configuration property with the given value. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.util.Map<java.lang.String,CRSConfiguration> DEFINED_CONFIGURATIONS
Method Detail |
---|
public static CRSConfiguration getCRSConfiguration(java.lang.String providerName)
DeegreeCRSProvider
will be
returned.
providerName
- the canonical name of the class, e.g. org.deegree.crs.MyProvider
CRSConfigurationException
- if --anything-- went wrong while instantiating the CRSProvider.public static CRSConfiguration getCRSConfiguration() throws CRSConfigurationException
DeegreeCRSProvider
will be used.
CRSConfigurationException
- if --anything-- went wrong while instantiating the CRSProvider.public static java.lang.String setDefaultFileProperty(java.lang.String fileName)
fileName
- to set the crs.configuration property to.
CRSConfigurationException
- if --anything-- went wrong while instantiating the CRSProvider.public static void main(java.lang.String[] args) throws java.lang.Exception
args
-
java.lang.Exception
public final CRSProvider getProvider()
public java.lang.String toString()
toString
in class java.lang.Object
|
deegree 2.5 (2011/06/29 09:44 build-8-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org