@DisplayName("User-defined coordinate transformations")
public class Test3208
extends Series3000<Transformation>
Verifies that the software allows correct definition of a user-defined transformations.
Test method: | Create user-defined transformations. |
---|---|
Test data: | GIGS_user_3208_CoordTfm.txt
|
Tested API: | MathTransformFactory.getDefaultParameters(String) andCoordinateOperationFactory.createTransformation(Map, CoordinateReferenceSystem, CoordinateReferenceSystem, OperationMethod, MathTransform) . |
Expected result: | The geoscience software should accept the test data. The order in which the transformation parameters are entered is not critical, although that given in the test dataset is recommended. |
Usage example
in order to specify their factories and run the tests in a JUnit framework, implementers can define a subclass in their own test suite as in the example below:public class MyTest extends Test3208 {
public MyTest() {
super(new MyFactories());
}
}
- Since:
- 1.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final CoordinateOperationFactory
The factory to use for creating transformation instances, ornull
if none.protected final CRSAuthorityFactory
Factory to use for buildingProjectedCRS
instances, ornull
if none.protected final CRSFactory
Factory to use for buildingGeodeticCRS
instances, ornull
if none.protected final DatumAuthorityFactory
protected final DatumFactory
Factory to use for buildingGeodeticDatum
instances, ornull
if none.Name of the transformation method.protected final MathTransformFactory
The factory to use for fetching operation methods, ornull
if none.The parameters defining the transformation to create.Fields inherited from class Series3000
isFactoryPreservingUserValues, properties
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the transformation instance to be tested.void
Tests “GIGS geogCRS X to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS E to GIGS geogCRS A (2)” transformation from the factory.void
Tests “GIGS geogCRS C to GIGS geogCRS A (2)” transformation from the factory.void
Tests “GIGS geogCRS A to WGS 84 (1)” transformation from the factory.void
Tests “GIGS geogCRS C to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS C to GIGS geogCRS A (3)” transformation from the factory.void
Tests “GIGS geogCRS J to GIGS geogCRS A (2)” transformation from the factory.void
Tests “GIGS geogCRS L to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS F to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS J to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS Z to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS T to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS B to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS K to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS Y to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS M to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS B to GIGS geogCRS A (2)” transformation from the factory.void
Tests “GIGS geogCRS E to GIGS geogCRS A (1)” transformation from the factory.void
Tests “GIGS geogCRS J to GIGS geogCRS A (3)” transformation from the factory.void
Tests “GIGS geogCRS D to GIGS geogCRS L (1)” transformation from the factory.void
Tests “GIGS geogCRS H to GIGS geogCRS T (1)” transformation from the factory.
-
Field Details
-
methodName
Name of the transformation method. -
parameters
The parameters defining the transformation to create. This field is set by all test methods before to create and verify theTransformation
instance. -
mtFactory
The factory to use for fetching operation methods, ornull
if none. -
copFactory
The factory to use for creating transformation instances, ornull
if none. -
crsFactory
Factory to use for buildingGeodeticCRS
instances, ornull
if none. -
datumFactory
Factory to use for buildingGeodeticDatum
instances, ornull
if none. May also be used for buildingEllipsoid
andPrimeMeridian
components. -
datumAuthorityFactory
Factory to use for buildingGeodeticDatum
andPrimeMeridian
components, ornull
if none. This is used only for tests with EPSG codes for datum components. -
crsAuthorityFactory
Factory to use for buildingProjectedCRS
instances, ornull
if none. This is the factory used by thegetIdentifiedObject()
method.
-
-
Constructor Details
-
Test3208
Creates a new test using the given factories. The factories needed by this class areCoordinateOperationFactory
,MathTransformFactory
,CRSFactory
,CSFactory
,DatumFactory
and optionallyCRSAuthorityFactory
withDatumAuthorityFactory
. If a requested factory isnull
, then the tests which depend on it will be skipped.Authority factory usage
The authority factory is used only for some test cases where the components are fetched by EPSG codes instead of being built by user. Those test cases are identified by the "definition source" line in Javadoc.- Parameters:
factories
- factories for creating the instances to test.
-
-
Method Details
-
getIdentifiedObject
Returns the transformation instance to be tested. When this method is invoked for the first time, it creates the transformation to test by invoking theMathTransformFactory.getDefaultParameters(String)
method with the currentmethodName
value in argument and then specifying the parameters by invokingMathTransformFactory.createParameterizedTransform(ParameterValueGroup)
. In order to create a transformation that is created from CRS and parameters, an implementation-specific API needs to be called. Details of the implementation-specific part are internal to GIGS test suite and will tentatively be removed with GeoAPI 3.1. The created object is then cached and returned in all subsequent invocations of this method.- Specified by:
getIdentifiedObject
in classSeries3000<Transformation>
- Returns:
- the transformation instance to test.
- Throws:
FactoryException
- if an error occurred while creating the transformation instance.
-
GIGS_61001
Tests “GIGS geogCRS A to WGS 84 (1)” transformation from the factory.- GIGS transformation code: 61001
- GIGS transformation name: GIGS geogCRS A to WGS 84 (1)
- EPSG Transformation Method: Geocentric translations
Transformation parameters Parameter name Value X-axis translation 0 metre Y-axis translation 0 metre Z-axis translation 0 metre - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61196
@Test @DisplayName("GIGS geogCRS B to GIGS geogCRS A (1)") public void GIGS_61196() throws FactoryExceptionTests “GIGS geogCRS B to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61196
- GIGS transformation name: GIGS geogCRS B to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1196 – OSGB36 to WGS 84 (2)
Transformation parameters Parameter name Value X-axis translation 371 metres Y-axis translation -112 metres Z-axis translation 434 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61314
@Test @DisplayName("GIGS geogCRS B to GIGS geogCRS A (2)") public void GIGS_61314() throws FactoryExceptionTests “GIGS geogCRS B to GIGS geogCRS A (2)” transformation from the factory.- GIGS transformation code: 61314
- GIGS transformation name: GIGS geogCRS B to GIGS geogCRS A (2)
- EPSG Transformation Method: Position Vector 7-param. transformation
- EPSG equivalence: 1314 – OSGB36 to WGS 84 (6)
Transformation parameters Parameter name Value X-axis translation 446.448 metres Y-axis translation -125.157 metres Z-axis translation 542.06 metres X-axis rotation 0.15 arc-second Y-axis rotation 0.247 arc-second Z-axis rotation 0.842 arc-second Scale difference -20.489 parts per millions - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61002
@Test @DisplayName("GIGS geogCRS C to GIGS geogCRS A (1)") public void GIGS_61002() throws FactoryExceptionTests “GIGS geogCRS C to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61002
- GIGS transformation name: GIGS geogCRS C to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
Transformation parameters Parameter name Value X-axis translation 593 metres Y-axis translation 26 metres Z-axis translation 479 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_15934
@Test @DisplayName("GIGS geogCRS C to GIGS geogCRS A (2)") public void GIGS_15934() throws FactoryExceptionTests “GIGS geogCRS C to GIGS geogCRS A (2)” transformation from the factory.- GIGS transformation code: 15934
- GIGS transformation name: GIGS geogCRS C to GIGS geogCRS A (2)
- EPSG Transformation Method: Coordinate Frame rotation
- EPSG equivalence: 15934 – Amersfoort to WGS 84 (3)
Transformation parameters Parameter name Value X-axis translation 565.2369 metres Y-axis translation 50.0087 metres Z-axis translation 465.658 metres X-axis rotation 1.9725 microradians Y-axis rotation -1.7004 microradians Z-axis rotation 9.0677 microradians Scale difference 4.0812 parts per millions - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61003
@Test @DisplayName("GIGS geogCRS C to GIGS geogCRS A (3)") public void GIGS_61003() throws FactoryExceptionTests “GIGS geogCRS C to GIGS geogCRS A (3)” transformation from the factory.- GIGS transformation code: 61003
- GIGS transformation name: GIGS geogCRS C to GIGS geogCRS A (3)
- EPSG Transformation Method: Molodensky-Badekas 10-parameter transformation
Transformation parameters Parameter name Value X-axis translation 593.0297 metres Y-axis translation 26.0038 metres Z-axis translation 478.7534 metres X-axis rotation 0.4069 arc-second Y-axis rotation -0.3507 arc-second Z-axis rotation 1.8703 arc-seconds Scale difference 4.0812 parts per millions Ordinate 1 of evaluation point 3903453.1482 metres Ordinate 2 of evaluation point 368135.3134 metres Ordinate 3 of evaluation point 5012970.3051 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61759
@Test @DisplayName("GIGS geogCRS D to GIGS geogCRS L (1)") public void GIGS_61759() throws FactoryExceptionTests “GIGS geogCRS D to GIGS geogCRS L (1)” transformation from the factory.- GIGS transformation code: 61759
- GIGS transformation name: GIGS geogCRS D to GIGS geogCRS L (1)
- EPSG Transformation Method: Longitude rotation
- EPSG equivalence: 1759 – Batavia (Jakarta) to Batavia (1)
Transformation parameters Parameter name Value Longitude offset 106°48′27.79″ (106.8077194°) - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61610
@Test @DisplayName("GIGS geogCRS E to GIGS geogCRS A (1)") public void GIGS_61610() throws FactoryExceptionTests “GIGS geogCRS E to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61610
- GIGS transformation name: GIGS geogCRS E to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1610 – BD72 to WGS 84 (2)
Transformation parameters Parameter name Value X-axis translation -125.8 metres Y-axis translation 79.9 metres Z-axis translation -100.5 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_15929
@Test @DisplayName("GIGS geogCRS E to GIGS geogCRS A (2)") public void GIGS_15929() throws FactoryExceptionTests “GIGS geogCRS E to GIGS geogCRS A (2)” transformation from the factory.- GIGS transformation code: 15929
- GIGS transformation name: GIGS geogCRS E to GIGS geogCRS A (2)
- EPSG Transformation Method: Coordinate Frame rotation
- EPSG equivalence: 15929 – BD72 to WGS 84 (3)
Transformation parameters Parameter name Value X-axis translation -106.8686 metres Y-axis translation 52.2978 metres Z-axis translation -103.7239 metres X-axis rotation -0.3366 arc-second Y-axis rotation 0.457 arc-second Z-axis rotation -1.8422 arc-seconds Scale difference -1.2747 parts per millions - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61150
@Test @DisplayName("GIGS geogCRS F to GIGS geogCRS A (1)") public void GIGS_61150() throws FactoryExceptionTests “GIGS geogCRS F to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61150
- GIGS transformation name: GIGS geogCRS F to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1150 – GDA94 to WGS 84 (1)
Transformation parameters Parameter name Value X-axis translation 0 metre Y-axis translation 0 metre Z-axis translation 0 metre - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61763
@Test @DisplayName("GIGS geogCRS H to GIGS geogCRS T (1)") public void GIGS_61763() throws FactoryExceptionTests “GIGS geogCRS H to GIGS geogCRS T (1)” transformation from the factory.- GIGS transformation code: 61763
- GIGS transformation name: GIGS geogCRS H to GIGS geogCRS T (1)
- EPSG Transformation Method: Longitude rotation
- EPSG equivalence: 1763 – NTF (Paris) to NTF (1)
Transformation parameters Parameter name Value Longitude offset 2.5969213 grads - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61173
@Test @DisplayName("GIGS geogCRS J to GIGS geogCRS A (1)") public void GIGS_61173() throws FactoryExceptionTests “GIGS geogCRS J to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61173
- GIGS transformation name: GIGS geogCRS J to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1173 – NAD27 to WGS 84 (4)
Transformation parameters Parameter name Value X-axis translation -8 metres Y-axis translation 160 metres Z-axis translation 176 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61004
@Test @DisplayName("GIGS geogCRS J to GIGS geogCRS A (2)") public void GIGS_61004() throws FactoryExceptionTests “GIGS geogCRS J to GIGS geogCRS A (2)” transformation from the factory.- GIGS transformation code: 61004
- GIGS transformation name: GIGS geogCRS J to GIGS geogCRS A (2)
- EPSG Transformation Method: NADCON
Transformation parameters Parameter name Value Latitude difference file n_slope.las Longitude difference file n_slope.los - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61692
@Test @DisplayName("GIGS geogCRS J to GIGS geogCRS A (3)") public void GIGS_61692() throws FactoryExceptionTests “GIGS geogCRS J to GIGS geogCRS A (3)” transformation from the factory.- GIGS transformation code: 61692
- GIGS transformation name: GIGS geogCRS J to GIGS geogCRS A (3)
- EPSG Transformation Method: NTv2
- EPSG equivalence: 1692 – NAD27 to WGS 84 (34)
Transformation parameters Parameter name Value Latitude and longitude difference file QUE27-98.gsb - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61242
@Test @DisplayName("GIGS geogCRS K to GIGS geogCRS A (1)") public void GIGS_61242() throws FactoryExceptionTests “GIGS geogCRS K to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61242
- GIGS transformation name: GIGS geogCRS K to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1242 – HD72 to WGS 84 (4)
Transformation parameters Parameter name Value X-axis translation 52.17 metres Y-axis translation -71.82 metres Z-axis translation -14.9 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61123
@Test @DisplayName("GIGS geogCRS L to GIGS geogCRS A (1)") public void GIGS_61123() throws FactoryExceptionTests “GIGS geogCRS L to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61123
- GIGS transformation name: GIGS geogCRS L to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 8452 – Batavia to WGS 84 (1)
Transformation parameters Parameter name Value X-axis translation -377 metres Y-axis translation 681 metres Z-axis translation -50 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61275
@Test @DisplayName("GIGS geogCRS M to GIGS geogCRS A (1)") public void GIGS_61275() throws FactoryExceptionTests “GIGS geogCRS M to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61275
- GIGS transformation name: GIGS geogCRS M to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1275 – ED50 to WGS 84 (17)
Transformation parameters Parameter name Value X-axis translation -84 metres Y-axis translation -97 metres Z-axis translation -117 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61193
@Test @DisplayName("GIGS geogCRS T to GIGS geogCRS A (1)") public void GIGS_61193() throws FactoryExceptionTests “GIGS geogCRS T to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61193
- GIGS transformation name: GIGS geogCRS T to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1193 – NTF to WGS 84 (1)
Transformation parameters Parameter name Value X-axis translation -168 metres Y-axis translation -60 metres Z-axis translation 320 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_15788
@Test @DisplayName("GIGS geogCRS X to GIGS geogCRS A (1)") public void GIGS_15788() throws FactoryExceptionTests “GIGS geogCRS X to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 15788
- GIGS transformation name: GIGS geogCRS X to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 15788 – AGD66 to WGS 84 (16)
Transformation parameters Parameter name Value X-axis translation -127.8 metres Y-axis translation -52.3 metres Z-axis translation 152.9 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61254
@Test @DisplayName("GIGS geogCRS Y to GIGS geogCRS A (1)") public void GIGS_61254() throws FactoryExceptionTests “GIGS geogCRS Y to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61254
- GIGS transformation name: GIGS geogCRS Y to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1254 – Pulkovo 1942 to WGS 84 (1)
Transformation parameters Parameter name Value X-axis translation 28 metres Y-axis translation -130 metres Z-axis translation -95 metres - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-
GIGS_61188
@Test @DisplayName("GIGS geogCRS Z to GIGS geogCRS A (1)") public void GIGS_61188() throws FactoryExceptionTests “GIGS geogCRS Z to GIGS geogCRS A (1)” transformation from the factory.- GIGS transformation code: 61188
- GIGS transformation name: GIGS geogCRS Z to GIGS geogCRS A (1)
- EPSG Transformation Method: Geocentric translations
- EPSG equivalence: 1188 – NAD83 to WGS 84 (1)
Transformation parameters Parameter name Value X-axis translation 0 metre Y-axis translation 0 metre Z-axis translation 0 metre - Throws:
FactoryException
- if an error occurred while creating the transformation from the properties.
-