org.geotools.referencing.crs
Class EPSGCRSAuthorityFactory

Object
  extended by AbstractFactory
      extended by EPSGCRSAuthorityFactory
All Implemented Interfaces:
RegisterableService, Factory, AuthorityFactory, CRSAuthorityFactory

Deprecated. Uses one of the other EPSG factories backed by a database instead.

public class EPSGCRSAuthorityFactory
extends AbstractFactory
implements CRSAuthorityFactory

Default implementation for a coordinate reference system authority factory backed by the EPSG property file. This gives most of the benifits of using the EPSG database backed authority factory, in a nice, portable property file.

Author:
Jody Garnett, Rueben Schulz

Field Summary
static String AUTHORITY
          Deprecated.  
static String AUTHORITY_PREFIX
          Deprecated.  
protected  CRSFactory crsFactory
          Deprecated.  
protected static EPSGCRSAuthorityFactory DEFAULT
          Deprecated. The default coordinate system authority factory.
protected  Properties epsg
          Deprecated. The properties object for our properties file.
 
Fields inherited from class AbstractFactory
hints, MAXIMUM_PRIORITY, MINIMUM_PRIORITY, NORMAL_PRIORITY, priority
 
Constructor Summary
  EPSGCRSAuthorityFactory()
          Deprecated. Loads from epsg.properties if the file exists, defaults to internal defintions exported from postgis and cubeworks.
protected EPSGCRSAuthorityFactory(CRSFactory factory)
          Deprecated. Loads from epsg.properties if the file exists, defaults to internal defintions exported from postgis and cubeworks.
protected EPSGCRSAuthorityFactory(CRSFactory factory, URL definition)
          Deprecated.  
 
Method Summary
 CompoundCRS createCompoundCRS(String str)
          Deprecated. Creates a 3D coordinate reference system from a code.
 CoordinateReferenceSystem createCoordinateReferenceSystem(String code)
          Deprecated. Returns an arbitrary coordinate reference system from a code.
 DerivedCRS createDerivedCRS(String str)
          Deprecated. Creates a derived coordinate reference system from a code.
 EngineeringCRS createEngineeringCRS(String str)
          Deprecated. Create a engineering coordinate reference system from a code.
 GeocentricCRS createGeocentricCRS(String str)
          Deprecated. Returns a geocentric coordinate reference system from a code.
 GeographicCRS createGeographicCRS(String code)
          Deprecated. Returns a geographic coordinate reference system from a code.
 ImageCRS createImageCRS(String str)
          Deprecated. Create a image coordinate reference system from a code.
 IdentifiedObject createObject(String code)
          Deprecated. Returns an arbitrary object from a code.
 ProjectedCRS createProjectedCRS(String code)
          Deprecated. Returns a projected coordinate reference system from a code.
 TemporalCRS createTemporalCRS(String str)
          Deprecated. Create a temporal coordinate reference system from a code.
 VerticalCRS createVerticalCRS(String str)
          Deprecated. Create a vertical coordinate reference system from a code.
 Citation getAuthority()
          Deprecated. Returns the organization or party responsible for definition and maintenance of the database.
 Set getAuthorityCodes(Class clazz)
          Deprecated. Returns the set of authority codes of the given type.
static CRSAuthorityFactory getDefault()
          Deprecated. Returns a default coordinate system factory backed by the EPSG property file.
 InternationalString getDescriptionText(String code)
          Deprecated. Gets a description of the object corresponding to a code.
 ObjectFactory getObjectFactory()
          Deprecated.  
 Citation getVendor()
          Deprecated. Returns the vendor responsible for creating this factory implementation.
protected  void loadDefault()
          Deprecated. Loads from epsg.properties if the file exists, defaults to internal defintions exported from postgis and cubeworks.
 
Methods inherited from class AbstractFactory
addImplementationHints, equals, getImplementationHints, getPriority, hashCode, onDeregistration, onRegistration, toString
 
Methods inherited from class Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

AUTHORITY

public static final String AUTHORITY
Deprecated. 
See Also:
Constant Field Values

AUTHORITY_PREFIX

public static final String AUTHORITY_PREFIX
Deprecated. 
See Also:
Constant Field Values

DEFAULT

protected static EPSGCRSAuthorityFactory DEFAULT
Deprecated. 
The default coordinate system authority factory. Will be constructed only when first requested.


epsg

protected Properties epsg
Deprecated. 
The properties object for our properties file. Keys are the EPSG code for a coordinate reference system and the associated value is a WKT string for the CRS.


crsFactory

protected CRSFactory crsFactory
Deprecated. 
Constructor Detail

EPSGCRSAuthorityFactory

public EPSGCRSAuthorityFactory()
Deprecated. 
Loads from epsg.properties if the file exists, defaults to internal defintions exported from postgis and cubeworks.


EPSGCRSAuthorityFactory

protected EPSGCRSAuthorityFactory(CRSFactory factory)
Deprecated. 
Loads from epsg.properties if the file exists, defaults to internal defintions exported from postgis and cubeworks.


EPSGCRSAuthorityFactory

protected EPSGCRSAuthorityFactory(CRSFactory factory,
                                  URL definition)
                           throws FactoryException
Deprecated. 
Throws:
FactoryException
Method Detail

loadDefault

protected void loadDefault()
                    throws IOException
Deprecated. 
Loads from epsg.properties if the file exists, defaults to internal defintions exported from postgis and cubeworks.

Throws:
IOException

getDefault

public static CRSAuthorityFactory getDefault()
Deprecated. 
Returns a default coordinate system factory backed by the EPSG property file.

Returns:
The default factory.
Throws:
SQLException - if the connection to the database can't be etablished.

createCoordinateReferenceSystem

public CoordinateReferenceSystem createCoordinateReferenceSystem(String code)
                                                          throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Returns an arbitrary coordinate reference system from a code. If the coordinate reference system type is know at compile time, it is recommended to invoke the most precise method instead of this one (for example  createGeographicCRS(code)  instead of  createCoordinateReferenceSystem(code)  if the caller know he is asking for a geographic coordinate reference system).

Specified by:
createCoordinateReferenceSystem in interface CRSAuthorityFactory
Parameters:
code - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.
See Also:
CRSAuthorityFactory.createGeographicCRS(java.lang.String), CRSAuthorityFactory.createProjectedCRS(java.lang.String), CRSAuthorityFactory.createVerticalCRS(java.lang.String), CRSAuthorityFactory.createTemporalCRS(java.lang.String), CRSAuthorityFactory.createCompoundCRS(java.lang.String)

createObject

public IdentifiedObject createObject(String code)
                              throws FactoryException
Deprecated. 
Description copied from interface: AuthorityFactory
Returns an arbitrary object from a code. The returned object will typically be an instance of Datum, CoordinateSystem, ReferenceSystem or CoordinateOperation. If the type of the object is know at compile time, it is recommended to invoke the most precise method instead of this one (for example  createCoordinateReferenceSystem(code)  instead of  createObject(code)  if the caller know he is asking for a coordinate reference system).

Specified by:
createObject in interface AuthorityFactory
Parameters:
code - Value allocated by authority.
Returns:
The object for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.
See Also:
DatumAuthorityFactory.createDatum(java.lang.String), CRSAuthorityFactory.createCoordinateReferenceSystem(java.lang.String)

createProjectedCRS

public ProjectedCRS createProjectedCRS(String code)
                                throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Returns a projected coordinate reference system from a code.

Specified by:
createProjectedCRS in interface CRSAuthorityFactory
Parameters:
code - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.
See Also:
DatumAuthorityFactory.createGeodeticDatum(java.lang.String)

createGeographicCRS

public GeographicCRS createGeographicCRS(String code)
                                  throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Returns a geographic coordinate reference system from a code.

Specified by:
createGeographicCRS in interface CRSAuthorityFactory
Parameters:
code - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.
See Also:
DatumAuthorityFactory.createGeodeticDatum(java.lang.String)

getAuthority

public Citation getAuthority()
Deprecated. 
Description copied from interface: AuthorityFactory
Returns the organization or party responsible for definition and maintenance of the database.

Specified by:
getAuthority in interface AuthorityFactory
Returns:
The organization reponsible for definition of the database.

getAuthorityCodes

public Set getAuthorityCodes(Class clazz)
                      throws FactoryException
Deprecated. 
Returns the set of authority codes of the given type. The type argument specify the base class. For example if this factory is an instance of CRSAuthorityFactory, then: The following implementaiton filters the set of codes based on the "PROJCS" and "GEOGCS" at the start of the WKT strings. It is assumed that we only have GeographicCRS and ProjectedCRS's here.

Specified by:
getAuthorityCodes in interface AuthorityFactory
Parameters:
clazz - The spatial reference objects type (may be Object.class).
Returns:
The set of authority codes for spatial reference objects of the given type. If this factory doesn't contains any object of the given type, then this method returns an empty set.
Throws:
FactoryException - if access to the underlying database failed.

getObjectFactory

public ObjectFactory getObjectFactory()
Deprecated. 

getVendor

public Citation getVendor()
Deprecated. 
Description copied from interface: Factory
Returns the vendor responsible for creating this factory implementation. Many implementations may be available for the same factory interface. Implementations are usually managed by a service registry.

Returns:
The vendor for this factory implementation.

getDescriptionText

public InternationalString getDescriptionText(String code)
                                       throws FactoryException
Deprecated. 
Description copied from interface: AuthorityFactory
Gets a description of the object corresponding to a code.

Specified by:
getDescriptionText in interface AuthorityFactory
Parameters:
code - Value allocated by authority.
Returns:
A description of the object, or null if the object corresponding to the specified code has no description.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the query failed for some other reason.

createCompoundCRS

public CompoundCRS createCompoundCRS(String str)
                              throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Creates a 3D coordinate reference system from a code.

Specified by:
createCompoundCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.

createDerivedCRS

public DerivedCRS createDerivedCRS(String str)
                            throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Creates a derived coordinate reference system from a code.

Specified by:
createDerivedCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.

createEngineeringCRS

public EngineeringCRS createEngineeringCRS(String str)
                                    throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Create a engineering coordinate reference system from a code.

Specified by:
createEngineeringCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.

createGeocentricCRS

public GeocentricCRS createGeocentricCRS(String str)
                                  throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Returns a geocentric coordinate reference system from a code.

Specified by:
createGeocentricCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed.
See Also:
DatumAuthorityFactory.createGeodeticDatum(java.lang.String)

createImageCRS

public ImageCRS createImageCRS(String str)
                        throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Create a image coordinate reference system from a code.

Specified by:
createImageCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.

createTemporalCRS

public TemporalCRS createTemporalCRS(String str)
                              throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Create a temporal coordinate reference system from a code.

Specified by:
createTemporalCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.
See Also:
DatumAuthorityFactory.createTemporalDatum(java.lang.String)

createVerticalCRS

public VerticalCRS createVerticalCRS(String str)
                              throws FactoryException
Deprecated. 
Description copied from interface: CRSAuthorityFactory
Create a vertical coordinate reference system from a code.

Specified by:
createVerticalCRS in interface CRSAuthorityFactory
Parameters:
str - Value allocated by authority.
Returns:
The coordinate reference system for the given code.
Throws:
NoSuchAuthorityCodeException - if the specified code was not found.
FactoryException - if the object creation failed for some other reason.
See Also:
DatumAuthorityFactory.createVerticalDatum(java.lang.String)


Copyright © 1996-2014 Geotools. All Rights Reserved.