org.geotoolkit.referencing.operation
Class AuthorityBackedFactory
Object
Factory
ReferencingFactory
AbstractCoordinateOperationFactory
DefaultCoordinateOperationFactory
AuthorityBackedFactory
- All Implemented Interfaces:
- ObjectFactory, CoordinateOperationFactory, Factory
@ThreadSafe
public class AuthorityBackedFactory
- extends DefaultCoordinateOperationFactory
A coordinate operation factory extended with the extra
informations provided by an authority factory.
Such authority factory may help to find transformation paths not available otherwise (often
determined from empirical parameters). Authority factories can also provide additional
informations like the
domain of validity,
scope and
accuracy.
When createOperation(sourceCRS, targetCRS) is invoked,
AuthorityBackedFactory fetches the authority codes for source and target CRS and submits
them to the underlying authority factory through a call to its
createFromCoordinateReferenceSystemCodes(sourceCode, targetCode) method. If the
authority factory doesn't know about the specified CRS, then the default (standalone)
process from the super-class is used as a fallback.
- Since:
- 2.2
- Version:
- 3.16
- Author:
- Martin Desruisseaux (IRD, Geomatys)
- Module:
| Methods inherited from class DefaultCoordinateOperationFactory |
createOperation, createOperation, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep, createOperationStep |
| Methods inherited from class AbstractCoordinateOperationFactory |
concatenate, concatenate, createConcatenatedOperation, createDefiningConversion, createFromAffineTransform, createFromMathTransform, createFromMathTransform, createFromParameters, createOperationMethod, getErrorMessage, getImplementationHints, getMathTransformFactory, getOperationMethod, inverse, swapAndScaleAxis |
AuthorityBackedFactory
public AuthorityBackedFactory()
- Creates a new factory backed by a default EPSG authority factory.
AuthorityBackedFactory
public AuthorityBackedFactory(Hints userHints)
- Creates a new factory backed by an authority factory fetched using the specified hints.
This constructor recognizes the
CRS, CS,
DATUM and MATH_TRANSFORM
FACTORY hints.
- Parameters:
userHints - The hints, or null if none.
setOrdering
protected void setOrdering(Factory.Organizer organizer)
- Invoked by
FactoryRegistry in order to set the ordering
relative to other factories. The current implementation specifies that this factory
should have priority over a plain (not backed by an authority)
DefaultCoordinateOperationFactory.
- Overrides:
setOrdering in class DefaultCoordinateOperationFactory
- Since:
- 3.00
getAuthorityFactory
protected CoordinateOperationAuthorityFactory getAuthorityFactory()
- Returns the underlying coordinate operation authority factory. This is the factory
where this
AuthorityBackedFactory will search for an explicitly specified
operation before to fallback to the super-class.
- Returns:
- The underlying coordinate operation authority factory.
createFromDatabase
protected CoordinateOperation createFromDatabase(CoordinateReferenceSystem sourceCRS,
CoordinateReferenceSystem targetCRS)
- Returns an operation for conversion or transformation between two coordinate reference
systems. The default implementation extracts the authority code from the supplied
sourceCRS and targetCRS, and submit them to the
createFromCoordinateReferenceSystemCodes(sourceCode, targetCode) methods.
If no operation is found for those codes, then this method returns null.
- Overrides:
createFromDatabase in class DefaultCoordinateOperationFactory
- Parameters:
sourceCRS - Input coordinate reference system.targetCRS - Output coordinate reference system.
- Returns:
- A coordinate operation from
sourceCRS to targetCRS, or null
if no such operation is explicitly defined in the underlying database. - Since:
- 2.3
accept
protected boolean accept(CoordinateOperation operation)
- Returns
true if the specified operation is acceptable. This method is invoked
automatically by createFromDatabase(...)
for every operation candidates found. The default implementation returns always true. Subclasses should override this method if they wish to filter the coordinate
operations to be returned.
- Parameters:
operation - The operation that createFromDatabase wants to return.
- Returns:
true if the given operation is acceptable, or false if
createFromDatabase should look for an other one.- Since:
- 2.3
availability
public ConformanceResult availability()
- Returns whatever this factory and its underlying
authority factory are available for use.
- Overrides:
availability in class Factory
- Since:
- 3.03
Copyright © 2009-2011 Geotoolkit.org. All Rights Reserved.