|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.deegree_impl.model.ct.AbstractMathTransform
Provides a default implementations for most methods required by the
MathTransform interface. AbstractMathTransform
provides a convenient base class from which other transform classes
can be easily derived. In addition, AbstractMathTransform
implements methods required by the MathTransform2D interface,
but does not implements MathTransform2D.
Subclasses must declare implements MathTransform2D
themself if they know to maps two-dimensional coordinate systems.
| Nested Class Summary | |
protected class |
AbstractMathTransform.Inverse
Default implementation for inverse math transform. |
| Constructor Summary | |
AbstractMathTransform()
Construct a math transform. |
|
| Method Summary | |
(package private) static void |
addParameter(java.lang.StringBuffer buffer,
java.lang.String key,
double value)
Add the ", PARAMETER[" string
to the specified string buffer. |
(package private) static void |
addParameter(java.lang.StringBuffer buffer,
java.lang.String key,
int value)
Add the ", PARAMETER[" string
to the specified string buffer. |
java.awt.Shape |
createTransformedShape(java.awt.Shape shape)
Transform the specified shape. |
(package private) java.awt.Shape |
createTransformedShape(java.awt.Shape shape,
java.awt.geom.AffineTransform preTr,
java.awt.geom.AffineTransform postTr,
int quadDir)
Transforme une forme géométrique. |
Matrix |
derivative(CoordinatePoint point)
Gets the derivative of this transform at a point. |
Matrix |
derivative(java.awt.geom.Point2D point)
Gets the derivative of this transform at a point. |
boolean |
equals(java.lang.Object object)
Compares the specified object with this math transform for equality. |
protected java.lang.String |
getName(java.util.Locale locale)
Returns a human readable name, if available. |
int |
hashCode()
Returns a hash value for this transform. |
MathTransform |
inverse()
Creates the inverse transform of this object. |
private static Matrix |
invert(Matrix matrix)
Invert the specified matrix in place. |
(package private) static java.lang.StringBuffer |
paramMT(java.lang.String classification)
Returns a string buffer initialized with "PARAM_MT" and a classification name. |
(package private) java.lang.Object |
toOpenGIS(java.lang.Object adapters)
Returns an OpenGIS interface for this math transform. |
java.lang.String |
toString()
Returns a string représentation of this transform. |
CoordinatePoint |
transform(CoordinatePoint ptSrc,
CoordinatePoint ptDst)
Transforms the specified ptSrc and stores the result
in ptDst. |
void |
transform(float[] srcPts,
int srcOff,
float[] dstPts,
int dstOff,
int numPts)
Transforms a list of coordinate point ordinal values. |
java.awt.geom.Point2D |
transform(java.awt.geom.Point2D ptSrc,
java.awt.geom.Point2D ptDst)
Transforms the specified ptSrc and stores the result in ptDst.
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.deegree_impl.model.ct.MathTransform |
getDimSource, getDimTarget, isIdentity, transform |
| Constructor Detail |
public AbstractMathTransform()
| Method Detail |
protected java.lang.String getName(java.util.Locale locale)
null. The default implementation always returns null.
locale - The desired locale, or null for a default locale.
null if no name is available in any locale.
public java.awt.geom.Point2D transform(java.awt.geom.Point2D ptSrc,
java.awt.geom.Point2D ptDst)
throws TransformException
ptSrc and stores the result in ptDst.
The default implementation invokes MathTransform.transform(double[],int,double[],int,int)
using a temporary array of doubles.
ptSrc - the specified coordinate point to be transformed.ptDst - the specified coordinate point that stores the
result of transforming ptSrc, or
null.
ptSrc
and stroring the result in ptDst.
MismatchedDimensionException - if this transform
doesn't map two-dimensional coordinate systems.
TransformException - if the point can't be transformed.MathTransform2D.transform(Point2D,Point2D)
public CoordinatePoint transform(CoordinatePoint ptSrc,
CoordinatePoint ptDst)
throws TransformException
ptSrc and stores the result
in ptDst. The default implementation invokes
MathTransform.transform(double[],int,double[],int,int).
transform in interface MathTransformptSrc - the specified coordinate point to be transformed.ptDst - the specified coordinate point that stores the
result of transforming ptSrc, or
null.
ptSrc
and storing the result in ptDst, or a newly
created point if ptDst was null.
TransformException - if the point can't be transformed.
public void transform(float[] srcPts,
int srcOff,
float[] dstPts,
int dstOff,
int numPts)
throws TransformException
MathTransform.transform(double[],int,double[],int,int) using a temporary array
of doubles.
transform in interface MathTransformsrcPts - 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
than srcPts.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.
TransformException - if a point can't be transformed.
public java.awt.Shape createTransformedShape(java.awt.Shape shape)
throws TransformException
shape - Shape to transform.
shape if
this transform is the identity transform.
java.lang.IllegalStateException - if this transform doesn't map 2D coordinate systems.
TransformException - if a transform failed.MathTransform2D.createTransformedShape(Shape)
final java.awt.Shape createTransformedShape(java.awt.Shape shape,
java.awt.geom.AffineTransform preTr,
java.awt.geom.AffineTransform postTr,
int quadDir)
throws TransformException
GeneralPath. Elle peut aussi retourner des objets Line2D ou
QuadCurve2D si une telle simplification est possible.
shape - Forme géométrique à transformer.preTr - Transformation affine à appliquer avant de transformer la forme
shape, ou null pour ne pas en appliquer.
Cet argument sera surtout utile lors des transformations inverses.postTr - Transformation affine à appliquer après avoir transformée la
forme shape, ou null pour ne pas en appliquer.
Cet argument sera surtout utile lors des transformations directes.quadDir - Direction des courbes quadratiques (Geometry.HORIZONTAL
ou Geometry.PARALLEL).
MismatchedDimensionException - if this transform
doesn't map two-dimensional coordinate systems.
TransformException - Si une transformation a échoué.
public Matrix derivative(java.awt.geom.Point2D point)
throws TransformException
derivative(CoordinatePoint).
point - The coordinate point where to evaluate the derivative.
MismatchedDimensionException - if the input dimension is not 2.
TransformException - if the derivative can't be evaluated at the specified point.MathTransform2D.derivative(Point2D)
public Matrix derivative(CoordinatePoint point)
throws TransformException
UnsupportedOperationException
(note: this default implementation may change in a future
version).
derivative in interface MathTransformpoint - The coordinate point where to evaluate the derivative.
null).
TransformException - if the derivative can't be evaluated at the specified point.
public MathTransform inverse()
throws NoninvertibleTransformException
this if this transform is an identity
transform, and throws a NoninvertibleTransformException otherwise. Subclasses
should override this method.
inverse in interface MathTransformNoninvertibleTransformException - if the transform can't be inversed.public int hashCode()
public boolean equals(java.lang.Object object)
object is an instance
of the same class than this. Subclasses should override
this method in order to compare internal fields.
public java.lang.String toString()
static java.lang.StringBuffer paramMT(java.lang.String classification)
static void addParameter(java.lang.StringBuffer buffer,
java.lang.String key,
double value)
", PARAMETER["", ]" string
to the specified string buffer. This is a convenience method
for constructing WKT for "PARAM_MT".
static void addParameter(java.lang.StringBuffer buffer,
java.lang.String key,
int value)
", PARAMETER["", ]" string
to the specified string buffer. This is a convenience method
for constructing WKT for "PARAM_MT".
java.lang.Object toOpenGIS(java.lang.Object adapters)
Object in order
to avoid too early class loading of OpenGIS interface.
private static Matrix invert(Matrix matrix)
throws NoninvertibleTransformException
SingularMatrixException, then the exception is
wrapped into a NoninvertibleTransformException.
NoninvertibleTransformException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||