TransformationCatalog

Allows discovery and management of the transformations used to convert coordinates between different datums. The transformation catalog class provides a mechanism for discovering available DatumTransformation objects. You can retrieve the default transformation used internally to convert coordinates, and find other available transformations. An area of interest may be taken into account.

This class also allows you to set the location where Projection Engine data files needed for some transformations are found on local storage. The TransformationCatalog.projectionEngineDirectory property must be set at process startup. Projection Engine data files are available in the downloads area of developers.arcgis.com[https://developers.arcgis.com/downloads/#pedata] (requires login).

The default transformation used when reprojecting geometries is the most suitable available transformation across the area covered by the input and output spatial references. You can sometimes get a more suitable transformation for work within a smaller area by specifying the extent of your specific work area, using TransformationCatalog.getTransformation(SpatialReference, SpatialReference, Envelope).

Since

200.1.0

Properties

Link copied to clipboard

The directory of the Projection Engine files on the local file system. This property should only be set upon process startup - a suitable point could be after license or license keys, but before any use of maps, maps views, scene views, or any other functionality that may involve geometry or projection functionality.

Functions

Link copied to clipboard
fun getTransformation(inputSpatialReference: SpatialReference, outputSpatialReference: SpatialReference, areaOfInterest: Envelope? = null, ignoreVertical: Boolean = false): DatumTransformation?

Returns the best usable transformation used to transform between the input and output spatial references, taking into account the area of interest, if specified. Optionally disregards any vertical transformations. Use this method to determine whether or not any vertical coordinate systems set on the spatial reference parameters should be accounted for in the returned transformation. This method can be used to replicate the former (prior to version 100.9.0) behavior of the TransformationCatalog.getTransformation(SpatialReference, SpatialReference) and TransformationCatalog.getTransformation(SpatialReference, SpatialReference, Envelope) methods:

Link copied to clipboard
fun getTransformationsBySuitability(inputSpatialReference: SpatialReference, outputSpatialReference: SpatialReference, areaOfInterest: Envelope? = null, ignoreVertical: Boolean = false): List<DatumTransformation>

Returns a collection of transformations suitable for projecting between the input and output spatial references, taking into account the area of interest, if specified. Optionally checks for suitable vertical transformations. The collection is ordered in descending order by suitability, with the most suitable being first in the list. The given area of interest can affect the number and order of transformations returned.