Authority factory for Coordinate Reference Systems beyong
the one defined in the EPSG database. This factory is used as a fallback when a requested code is
not found in the EPSG database, or when there is no connection at all to the EPSG database. The
additional CRS are defined as Well Known Text in a property file located by default
in the org.geotools.referencing.factory.epsg package, and whose name should be "epsg.properties". If no property file is found, the factory won't be activated. The property file can
also be located in a custom directory; See getDefinitionsURL() for more details.

This factory can also be used to provide custom extensions or overrides to a main EPSG
factory. In order to provide a custom extension file, override the getDefinitionsURL()
method. In order to make the factory be an override, change the default priority by using the two
arguments constructor (this factory defaults to ThreadedEpsgFactory.PRIORITY - 10, so
it's used as an extension).

Field Detail

FILENAME

The default filename to read. The default FactoryUsingWKT implementation will search
for the first occurence of this file in the following places:

In the directory specified by the system property.

In every org/geotools/referencing/factory/espg directories found on the
classpath.

The filename part before the extension ("epsg") denotes the authority namespace
where to register the content of this file. The user-directory given by the system property
may contains other property files for other authorities, like "esri.properties", but
those additional authorities are not handled by the default FactoryUsingWKT class.

FactoryUsingWKT

Method Detail

getAuthority

Returns the authority. The default implementation returns the first citation returned by
getAuthorities(), with the addition of identifiers from all additional authorities
returned by the above method.

getAuthorities

The default implementation returns a singleton containing only EPSG. Subclasses should override this method in order to enumerate all relevant authorities,
with EPSG in last position. For example EsriExtension
returns {ESRI, EPSG}.

getDefinitionsURL

Returns the URL to the property file that contains CRS definitions. The default
implementation performs the following search path:

If a value is set for the system property key, then the
"epsg.properties" file will be searched in this directory.

If no value is set for the above-cited system property, or if no "epsg.properties"
file was found in that directory, then the first "epsg.properties" file found in any
org/geotools/referencing/factory/epsg directory on the classpath will be used.

If no file was found on the classpath neither, then this factory will be disabled.

reportDuplicatedCodes

Prints a list of codes that duplicate the ones provided by ThreadedEpsgFactory. This
is used for implementation of main method in order to check the content of
the "epsg.properties" file (or whatever property file used as backing store for this
factory) from the command line.

reportInstantiationFailures

Prints a list of CRS that can't be instantiated. This is used for implementation of
main method in order to check the content of the "epsg.properties" file
(or whatever property file used as backing store for this factory) from the command line.

main

Prints a list of codes that duplicate the ones provided in the ThreadedEpsgFactory.
The factory tested is the one registered in ReferencingFactoryFinder. By default,
this is this FactoryUsingWKT class backed by the "epsg.properties" property file.
This method can be invoked from the command line in order to check the content of the
property file. Valid arguments are:

-test

Try to instantiate all CRS and reports any failure
to do so.

-duplicated

List all codes from the WKT factory that are
duplicating a code from the SQL factory.