org.geotoolkit.referencing.factory.web
Class WebCRSFactory
Object
Factory
ReferencingFactory
AbstractAuthorityFactory
DirectAuthorityFactory
WebCRSFactory
- All Implemented Interfaces:
- AuthorityFactory, CRSAuthorityFactory, Factory
@ThreadSafe
public class WebCRSFactory
- extends DirectAuthorityFactory
- implements CRSAuthorityFactory
The factory for coordinate reference systems in the
CRS namespace. The format is usually "CRS:n"
where n is a number like 27, 83 or 84. However this factory is lenient and allows
the CRS part to be repeated as in "CRS:CRS84". It also accepts "OGC"
as a synonymous of the "CRS" namespace. Examples:
"CRS:27"
"CRS:83"
"CRS:84"
"CRS:CRS84"
"OGC:CRS84"
- Since:
- 2.2
- Version:
- 3.00
- Author:
- Martin Desruisseaux (IRD)
- Module:
|
Constructor Summary |
WebCRSFactory()
Constructs a default factory for the CRS authority. |
WebCRSFactory(Hints userHints)
Constructs a factory for the CRS authority using the specified hints. |
| Methods inherited from class AbstractAuthorityFactory |
createCartesianCS, createCompoundCRS, createCoordinateOperation, createCoordinateSystem, createCoordinateSystemAxis, createCylindricalCS, createDatum, createDerivedCRS, createEllipsoid, createEllipsoidalCS, createEngineeringCRS, createEngineeringDatum, createExtent, createFromCoordinateReferenceSystemCodes, createGeocentricCRS, createGeodeticDatum, createGeographicCRS, createImageCRS, createImageDatum, createOperationMethod, createParameterDescriptor, createPolarCS, createPrimeMeridian, createProjectedCRS, createSphericalCS, createTemporalCRS, createTemporalDatum, createTimeCS, createUnit, createVerticalCRS, createVerticalCS, createVerticalDatum, dispose, getBackingStoreDescription, getIdentifiedObjectFinder, noSuchAuthorityCode, trimAuthority |
WebCRSFactory
public WebCRSFactory()
- Constructs a default factory for the
CRS authority.
WebCRSFactory
public WebCRSFactory(Hints userHints)
- Constructs a factory for the
CRS authority using the specified hints.
- Parameters:
userHints - An optional set of hints, or null for the default ones.
getAuthority
public Citation getAuthority()
- Returns the authority for this factory, which is
CRS.
- Specified by:
getAuthority in interface AuthorityFactory- Specified by:
getAuthority in class AbstractAuthorityFactory
getAuthorityCodes
public Set<String> getAuthorityCodes(Class<? extends IdentifiedObject> type)
throws FactoryException
- Provides a complete set of the known codes provided by this authority. The returned set
contains only numeric identifiers like
"84", "27", etc.
The authority name ("CRS") is not included. This is consistent with the
codes returned by the EPSG factory and avoid duplication, since the authority is the
same for every codes returned by this factory. It also make it easier for clients to
prepend whatever authority name they wish, as for example in the
all authorities factory.
- Specified by:
getAuthorityCodes in interface AuthorityFactory
- Throws:
FactoryException
getDescriptionText
public InternationalString getDescriptionText(String code)
throws FactoryException
- Returns the CRS name for the given code.
- Specified by:
getDescriptionText in interface AuthorityFactory
- Throws:
FactoryException - if an error occurred while fetching the description.
createObject
public IdentifiedObject createObject(String code)
throws FactoryException
- Creates an object from the specified code. The default implementation delegates to
createCoordinateReferenceSystem(code).
- Specified by:
createObject in interface AuthorityFactory- Overrides:
createObject in class AbstractAuthorityFactory
- Parameters:
code - Value allocated by authority.
- Throws:
FactoryException - if the object creation failed.
createCoordinateReferenceSystem
public CoordinateReferenceSystem createCoordinateReferenceSystem(String code)
throws FactoryException
- Creates a coordinate reference system from the specified code.
- Specified by:
createCoordinateReferenceSystem in interface CRSAuthorityFactory- Overrides:
createCoordinateReferenceSystem in class AbstractAuthorityFactory
- Parameters:
code - Value allocated by authority.
- Returns:
- The coordinate reference system for the given code.
- Throws:
FactoryException - if the object creation failed.
Copyright © 2009-2011 Geotoolkit.org. All Rights Reserved.