Skip To Content ArcGIS for Developers Sign In Dashboard

TransformationCatalog QML Type

Allows discovery and management of the transformations used to convert coordinates between different datums. More...

Import Statement: import Esri.ArcGISRuntime 100.9
Since: Esri.ArcGISRuntime 100.2
Inherits:

Object

Properties

Signals

Methods

Detailed Description

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

This class also lets you set the location where Projection Engine data files needed for some transformations are found on local storage. The TransformationCatalog::projectionEngineDirectory property must be set before using any geometry classes.

Default transformations

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::transformationsBySuitabilityWithAreaOfInterest.

See also TransformationCatalog::transformationsBySuitabilityWithAreaOfInterest.

Property Documentation

projectionEngineDirectory : string

The location where Projection Engine data files are found on the local file system.


Signal Documentation

projectionEngineDirectoryChanged()

Emitted when the projectionEngineDirectory property changes.

Note: The corresponding handler is onProjectionEngineDirectoryChanged.


Method Documentation

DatumTransformation transformation(inputSpatialReference, SpatialReference outputSpatialReference, Envelope areaOfInterest, bool ignoreVertical)

Returns the default 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.

  • inputSpatialReference - The spatial reference to use as the input.
  • outputSpatialReference - The spatial reference to use as the output.
  • areaOfInterest - The bounding box of coordinates to be transformed, or null to consider the entire world extent.
  • ignoreVertical - true if TransformationCatalog should ignore any vertical coordinate system set on the inputSpatialReference or outputSpatialReference, and only consider horizontal (geographic) transformations; false otherwise.

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 Esri.ArcGISRuntime 100.9) behavior of the TransformationCatalog::transformation(SpatialReference, SpatialReference) and TransformationCatalog::transformation(SpatialReference, SpatialReference, Envelope) methods:

Calling this method with `ignoreVertical == false` is equivalent to calling TransformationCatalog::transformation(SpatialReference, SpatialReference, Envelope). Calling this method with `ignoreVertical == true` is equivalent to calling TransformationCatalog::transformation(SpatialReference, SpatialReference, Envelope) in releases prior to Esri.ArcGISRuntime 100.9

This method was introduced in Esri.ArcGISRuntime 100.9.


DatumTransformation transformation(inputSpatialReference, SpatialReference outputSpatialReference, Envelope areaOfInterest)

Returns the default transformation used to transform between the input and output spatial references, taking into account the area of interest, if specified.

Returns null if no usable transformation is available for the given input parameters, or if no transformation is required.

  • inputSpatialReference - The spatial reference to use as the input.
  • outputSpatialReference - The spatial reference to use as the output.
  • areaOfInterest - The bounding box of coordinates to be transformed, or null to consider the entire world extent. If areaOfInterest is null or if Geometry::empty is true, the returned transformation does not take into account an area of interest, and the best choice for the entire world extent is effectively assumed. Otherwise, if areaOfInterest does not intersect the area of use of inputSpatialReference, this method returns null.

If areaOfInterest has a different spatial reference than inputSpatialReference, it will be reprojected to inputSpatialReference.


DatumTransformation transformation(inputSpatialReference, SpatialReference outputSpatialReference)

Returns the default transformation used to transform between the input and output spatial references, without taking into account an area of interest.

Returns null if no usable transformation is available for the given input parameters, or if no transformation is required.

The default transformation is the one used in cases such as when calling GeometryEngine::project without specifying a transformation.

See also TransformationCatalog::transformationsBySuitabilityWithAreaOfInterest.


list<DatumTransformation> transformationsBySuitability(inputSpatialReference, SpatialReference outputSpatialReference)

Returns a list containing DatumTransformation objects, each for projecting between spatial references without taking into account an area of interest.

The list is ordered in descending order by suitability, with the most suitable being first in the list. Some transformations require a supporting Projection Engine dataset to function correctly; see GeographicTransformationStep::projectionEngineFilenames. The list may include grid-based transformations, whether or not these datasets can be located by the Runtime; see DatumTransformation::missingProjectionEngineFiles.

See also TransformationCatalog::transformationsBySuitabilityWithAreaOfInterest.


list<DatumTransformation> transformationsBySuitabilityWithAreaOfInterest(inputSpatialReference, SpatialReference outputSpatialReference, Envelope areaOfInterest)

Returns a list containing DatumTransformation objects, each for projecting between spatial references and taking into account the area of interest.

The list is ordered in descending order by suitability, with the most suitable being first in the list. Note that providing an area of interest may affect the number and order of transformations returned. The list includes grid-based transformations, regardless of the presence or absence of required Projection Engine files supporting those transformations. To check for presence/absence of a supporting dataset, call GeographicTransformationStep::missingProjectionEngineFiles.

  • inputSpatialReference - The SpatialReference to use as the input.
  • outputSpatialReference - The SpatialReference to use as the output.
  • areaOfInterest - The bounding box of coordinates to be transformed, or null to consider the entire world extent. If areaOfInterest is null or if Geometry::empty, the returned transformation does not take into account an area of interest, and the best choice for the entire world extent is effectively assumed. Otherwise, if areaOfInterest does not intersect the area of use of inputSpatialReference, this method return an empty list. If areaOfInterest has a different spatial reference than inputSpatialReference, it will be reprojected to inputSpatialReference.

list<DatumTransformation> transformationsBySuitabilityWithAreaOfInterestAndIgnoreVertical(inputSpatialReference, SpatialReference outputSpatialReference, Envelope areaOfInterest, bool ignoreVertical)

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.

  • inputSpatialReference
  • outputSpatialReference
  • areaOfInterest - The bounding box of coordinates to be transformed, or null to consider the entire world extent.
  • ignoreVertical - true if TransformationCatalog should ignore any vertical coordinate systems set on the inputSpatialReference or outputSpatialReference, and only consider horizontal (geographic) transformations; false otherwise.

The collection is ordered in descending order by suitability, with the most suitable being first in the list.

A geographic transformation is not needed when input and output spatial references have the same underlying geographic coordinate system, in which case an empty list is returned. A vertical transformation is not needed if both datums (for ellipsoidal heights) or vertical datums (for gravity-related heights) are the same. If neither type of transformation is needed, an empty collection is returned.

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 list of transformations. This method can be used to replicate the former (prior to version Esri.ArcGISRuntime 100.9) behavior of the TransformationCatalog::transformationsBySuitability and TransformationCatalog::transformationsBySuitabilityWithAreaOfInterest methods:

Calling this method with `ignoreVertical == false` is equivalent to calling TransformationCatalog::transformationsBySuitabilityWithAreaOfInterest. Calling this method with `ignoreVertical == true` is equivalent to calling TransformationCatalog::transformationsBySuitabilityWithAreaOfInterest in releases prior to Esri.ArcGISRuntime 100.9

Some transformations require a supporting Projection Engine (PE) dataset to function correctly - see GeographicTransformationStep::projectionEngineFilenames and HorizontalVerticalTransformationStep::projectionEngineFilenames. The returned list may include grid-based transformations, whether or not these datasets can be located by the Runtime - see DatumTransformation::missingProjectionEngineFiles.

This method was introduced in Esri.ArcGISRuntime 100.9.



Feedback on this topic?