Class ConcatenatedTransformDirect
java.lang.Object
org.apache.sis.io.wkt.FormattableObject
org.apache.sis.referencing.operation.transform.AbstractMathTransform
org.apache.sis.referencing.operation.transform.ConcatenatedTransform
org.apache.sis.referencing.operation.transform.ConcatenatedTransformDirect
- All Implemented Interfaces:
Serializable
,Parameterized
,LenientComparable
,org.opengis.referencing.operation.MathTransform
- Direct Known Subclasses:
ConcatenatedTransformDirect1D
,ConcatenatedTransformDirect2D
Concatenated transform where the transfer dimension is the same than source and target dimension.
This fact allows some optimizations, the most important one being the possibility to avoid the use
of an intermediate buffer in some case.
- Since:
- 0.5
- Version:
- 0.5
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.sis.referencing.operation.transform.AbstractMathTransform
AbstractMathTransform.Inverse
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final long
Serial number for inter-operability with different versions.Fields inherited from class org.apache.sis.referencing.operation.transform.ConcatenatedTransform
transform1, transform2
Fields inherited from class org.apache.sis.referencing.operation.transform.AbstractMathTransform
MAXIMUM_BUFFER_SIZE, MAXIMUM_FAILURES
-
Constructor Summary
ConstructorsConstructorDescriptionConcatenatedTransformDirect
(org.opengis.referencing.operation.MathTransform transform1, org.opengis.referencing.operation.MathTransform transform2) Constructs a concatenated transform. -
Method Summary
Modifier and TypeMethodDescription(package private) boolean
isValid()
Checks if transforms are compatibles with this implementation.void
transform
(double[] srcPts, int srcOff, double[] dstPts, int dstOff, int numPts) Transforms many positions in a list of coordinate values.void
transform
(float[] srcPts, int srcOff, double[] dstPts, int dstOff, int numPts) Transforms many positions in a list of coordinate values.org.opengis.geometry.DirectPosition
transform
(org.opengis.geometry.DirectPosition ptSrc, org.opengis.geometry.DirectPosition ptDst) Transforms the specifiedptSrc
and stores the result inptDst
.Methods inherited from class org.apache.sis.referencing.operation.transform.ConcatenatedTransform
computeHashCode, create, derivative, equals, formatTo, getDomain, getParameterDescriptors, getParameterValues, getSourceDimensions, getSteps, getTargetDimensions, inverse, isIdentity, setInverse, transform, transform, transform, tryConcatenate
Methods inherited from class org.apache.sis.referencing.operation.transform.AbstractMathTransform
beforeFormat, equals, getContextualParameters, hashCode, isInverseEquals, mismatchedDimension
Methods inherited from class org.apache.sis.io.wkt.FormattableObject
print, toString, toString, toWKT
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.opengis.referencing.operation.MathTransform
toWKT
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDSerial number for inter-operability with different versions.- See Also:
-
-
Constructor Details
-
ConcatenatedTransformDirect
ConcatenatedTransformDirect(org.opengis.referencing.operation.MathTransform transform1, org.opengis.referencing.operation.MathTransform transform2) Constructs a concatenated transform.
-
-
Method Details
-
isValid
boolean isValid()Checks if transforms are compatibles with this implementation.- Overrides:
isValid
in classConcatenatedTransform
-
transform
public org.opengis.geometry.DirectPosition transform(org.opengis.geometry.DirectPosition ptSrc, org.opengis.geometry.DirectPosition ptDst) throws org.opengis.referencing.operation.TransformException Transforms the specifiedptSrc
and stores the result inptDst
.- Specified by:
transform
in interfaceorg.opengis.referencing.operation.MathTransform
- Overrides:
transform
in classConcatenatedTransform
- Parameters:
ptSrc
- the coordinate tuple to be transformed.ptDst
- the coordinate tuple that stores the result of transformingptSrc
, ornull
.- Returns:
- the coordinate tuple after transforming
ptSrc
and storing the result inptDst
, or a newly created point ifptDst
was null. - Throws:
org.opengis.referencing.operation.TransformException
- ifConcatenatedTransform.transform1
orConcatenatedTransform.transform2
failed.
-
transform
public void transform(double[] srcPts, int srcOff, double[] dstPts, int dstOff, int numPts) throws org.opengis.referencing.operation.TransformException Transforms many positions in a list of coordinate values.- Specified by:
transform
in interfaceorg.opengis.referencing.operation.MathTransform
- Overrides:
transform
in classConcatenatedTransform
- Parameters:
srcPts
- the array containing the source point coordinates.srcOff
- the offset to the first point to be transformed in the source array.dstPts
- the array into which the transformed point coordinates are returned. May be the same thansrcPts
.dstOff
- the offset to the location of the first transformed point that is stored in the destination array.numPts
- the number of point objects to be transformed.- Throws:
org.opengis.referencing.operation.TransformException
- ifConcatenatedTransform.transform1
orConcatenatedTransform.transform2
failed.
-
transform
public void transform(float[] srcPts, int srcOff, double[] dstPts, int dstOff, int numPts) throws org.opengis.referencing.operation.TransformException Transforms many positions in a list of coordinate values.- Specified by:
transform
in interfaceorg.opengis.referencing.operation.MathTransform
- Overrides:
transform
in classConcatenatedTransform
- Parameters:
srcPts
- the array containing the source point coordinates.srcOff
- the offset to the first point to be transformed in the source array.dstPts
- the array into which the transformed point coordinates are returned.dstOff
- the offset to the location of the first transformed point that is stored in the destination array.numPts
- the number of point objects to be transformed.- Throws:
org.opengis.referencing.operation.TransformException
- ifConcatenatedTransform.transform1
orConcatenatedTransform.transform2
failed.
-