sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1600998 - in /sis/branches/JDK7: ./ core/sis-feature/src/main/java/org/apache/sis/feature/ core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/ core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/tran...
Date Fri, 06 Jun 2014 20:28:53 GMT
Author: desruisseaux
Date: Fri Jun  6 20:28:52 2014
New Revision: 1600998

URL: http://svn.apache.org/r1600998
Log:
Merge from the JDK8 branch.

Added:
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PowerTransform1D.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PowerTransform1D.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/CoordinateDomain.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/CoordinateDomain.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/CopyTransformTest.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/CopyTransformTest.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/LinearTransformTest.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/LinearTransformTest.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/MathTransformFactoryBase.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/MathTransformFactoryBase.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/MathTransformTestCase.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/MathTransformTestCase.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/PassThroughTransformTest.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/PassThroughTransformTest.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/ProjectiveTransformTest.java
      - copied unchanged from r1600997, sis/branches/JDK8/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/ProjectiveTransformTest.java
Modified:
    sis/branches/JDK7/   (props changed)
    sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractAssociation.java
    sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java
  (contents, props changed)
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/DirectPositionView.java
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform1D.java
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform2D.java
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/LinearTransform.java
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PassThroughTransform.java
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/package-info.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/AbstractMathTransformTest.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/IterationStrategyTest.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/suite/ReferencingTestSuite.java

Propchange: sis/branches/JDK7/
------------------------------------------------------------------------------
  Merged /sis/branches/JDK8:r1600775-1600997

Modified: sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractAssociation.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractAssociation.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractAssociation.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractAssociation.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -170,7 +170,7 @@ public abstract class AbstractAssociatio
      * Sets the features. All previous values are replaced by the given collection.
      *
      * <p>The default implementation ensures that the given collection contains at
most one element,
-     * then delegates to {@link #setValue(AbstractFeature)}.</p>
+     * then delegates to {@link #setValue(Feature)}.</p>
      *
      * @param  values The new values.
      * @throws IllegalArgumentException if the given collection contains too many elements.

Modified: sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -150,7 +150,7 @@ public abstract class AbstractFeature im
      * }
      *
      * <div class="note"><b>Note:</b> This method is useful for storing
non-default {@code Attribute} or
-     * {@code Association} implementations in this feature. When default implementations
are sufficient,
+     * {@code FeatureAssociation} implementations in this feature. When default implementations
are sufficient,
      * the {@link #setPropertyValue(String, Object)} method is preferred.</div>
      *
      * @param  property The property to set.
@@ -239,11 +239,11 @@ public abstract class AbstractFeature im
      *
      * <table class="sis">
      *   <caption>Class of returned value</caption>
-     *   <tr><th>Property type</th>           <th>max. occurs</th>
<th>Method invoked</th>                  <th>Return type</th></tr>
-     *   <tr><td>{@link AttributeType}</td>   <td>0 or 1</td>
     <td>{@link Attribute#getValue()}</td>    <td>{@link Object}</td></tr>
-     *   <tr><td>{@code AttributeType}</td>   <td>2 or more</td>
  <td>{@link Attribute#getValues()}</td>   <td>{@code Collection<?>}</td></tr>
-     *   <tr><td>{@link AssociationRole}</td> <td>0 or 1</td>
     <td>{@link Association#getValue()}</td>  <td>{@link Feature}</td></tr>
-     *   <tr><td>{@code AssociationRole}</td> <td>2 or more</td>
  <td>{@link Association#getValues()}</td> <td>{@code Collection<Feature>}</td></tr>
+     *   <tr><th>Property type</th>           <th>max. occurs</th>
<th>Method invoked</th>                         <th>Return type</th></tr>
+     *   <tr><td>{@link AttributeType}</td>   <td>0 or 1</td>
     <td>{@link Attribute#getValue()}</td>           <td>{@link Object}</td></tr>
+     *   <tr><td>{@code AttributeType}</td>   <td>2 or more</td>
  <td>{@link Attribute#getValues()}</td>          <td>{@code Collection<?>}</td></tr>
+     *   <tr><td>{@link AssociationRole}</td> <td>0 or 1</td>
     <td>{@link FeatureAssociation#getValue()}</td>  <td>{@link Feature}</td></tr>
+     *   <tr><td>{@code AssociationRole}</td> <td>2 or more</td>
  <td>{@link FeatureAssociation#getValues()}</td> <td>{@code Collection<Feature>}</td></tr>
      * </table>
      *
      * <div class="note"><b>Note:</b> “max. occurs” is the {@linkplain
DefaultAttributeType#getMaximumOccurs() maximum

Propchange: sis/branches/JDK7/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java
------------------------------------------------------------------------------
  Merged /sis/branches/JDK8/core/sis-feature/src/main/java/org/apache/sis/feature/AbstractFeature.java:r1598745-1600997

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/DirectPositionView.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/DirectPositionView.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/DirectPositionView.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/DirectPositionView.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -18,9 +18,11 @@ package org.apache.sis.internal.referenc
 
 import java.util.Arrays;
 import org.opengis.geometry.DirectPosition;
-import org.opengis.geometry.UnmodifiableGeometryException;
 import org.opengis.referencing.crs.CoordinateReferenceSystem;
 
+// Branch-dependent imports
+import org.opengis.geometry.UnmodifiableGeometryException;
+
 
 /**
  * A read-only direct position wrapping an array without performing any copy.

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform1D.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform1D.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform1D.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform1D.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -39,6 +39,18 @@ import static org.apache.sis.util.Argume
  *   <li>{@link #derivative(double)}</li>
  * </ul>
  *
+ * {@section Immutability and thread safety}
+ * All Apache SIS implementations of {@code MathTransform1D} are immutable and thread-safe.
+ * It is highly recommended that third-party implementations be immutable and thread-safe
too.
+ * This means that unless otherwise noted in the javadoc, {@code MathTransform1D} instances
can
+ * be shared by many objects and passed between threads without synchronization.
+ *
+ * {@section Serialization}
+ * {@code MathTransform1D} may or may not be serializable, at implementation choices.
+ * Most Apache SIS implementations are serializable, but the serialized objects are not guaranteed
to be compatible
+ * with future SIS versions. Serialization should be used only for short term storage or
RMI between applications
+ * running the same SIS version.
+ *
  * @author  Martin Desruisseaux (Geomatys)
  * @since   0.5 (derived from geotk-3.17)
  * @version 0.5

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform2D.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform2D.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform2D.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/AbstractMathTransform2D.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -47,6 +47,18 @@ import org.apache.sis.util.resources.Err
  *
  * However more performance may be gained by overriding the other {@code transform} methods
as well.
  *
+ * {@section Immutability and thread safety}
+ * All Apache SIS implementations of {@code MathTransform2D} are immutable and thread-safe.
+ * It is highly recommended that third-party implementations be immutable and thread-safe
too.
+ * This means that unless otherwise noted in the javadoc, {@code MathTransform2D} instances
can
+ * be shared by many objects and passed between threads without synchronization.
+ *
+ * {@section Serialization}
+ * {@code MathTransform2D} may or may not be serializable, at implementation choices.
+ * Most Apache SIS implementations are serializable, but the serialized objects are not guaranteed
to be compatible
+ * with future SIS versions. Serialization should be used only for short term storage or
RMI between applications
+ * running the same SIS version.
+ *
  * @author  Martin Desruisseaux (Geomatys)
  * @since   0.5 (derived from geotk-2.0)
  * @version 0.5

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/LinearTransform.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/LinearTransform.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/LinearTransform.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/LinearTransform.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -50,17 +50,21 @@ import org.opengis.referencing.operation
  * A <cite>projective</cite> transform can be used as a generalization of affine
transforms.
  * In such case the computation performed by SIS is similar to {@code PerspectiveTransform}
  * in <cite>Java Advanced Imaging</cite>.
+ * For example a square matrix of size 4×4 is used for transforming three-dimensional coordinates.
+ * The transformed points {@code (x',y',z')} are computed as below:
  *
- * <p>For example a square matrix of size 4×4 is used for transforming three-dimensional
coordinates.
- * The transformed points {@code (x',y',z')} are computed as below:</p>
+ * <center><p>{@include formulas.html#ProjectiveTransform}</p></center>
  *
- * <blockquote>{@include formulas.html#ProjectiveTransform}</blockquote>
+ * {@section Instantiation}
+ * The easiest way to instantiate a {@code LinearTransform} is to use the {@link MathTransforms#linear(Matrix)}
+ * convenience method.
  *
  * @author  Martin Desruisseaux (IRD, Geomatys)
  * @since   0.4 (derived from geotk-2.0)
  * @version 0.4
  * @module
  *
+ * @see java.awt.geom.AffineTransform
  * @see <a href="http://mathworld.wolfram.com/AffineTransformation.html">Affine transformation
on MathWorld</a>
  */
 public interface LinearTransform extends MathTransform {
@@ -68,6 +72,7 @@ public interface LinearTransform extends
      * Returns the coefficients of this linear transform as a matrix.
      * Converting a coordinate with this {@code MathTransform} is equivalent to multiplying
the
      * returned matrix by a vector containing the ordinate values with an additional 1 in
the last row.
+     * See {@link LinearTransform} class Javadoc for more details.
      *
      * @return The coefficients of this linear transform as a matrix.
      *

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PassThroughTransform.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PassThroughTransform.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PassThroughTransform.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/PassThroughTransform.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -38,9 +38,23 @@ import static org.apache.sis.util.Argume
  * Transform which passes through a subset of ordinates to another transform.
  * This allows transforms to operate on a subset of ordinates.
  *
- * <span class="note"><b>Example:</b> giving (<var>latitude</var>,
<var>longitude</var>, <var>height</var>) coordinates,
+ * <div class="note"><b>Example:</b> giving (<var>latitude</var>,
<var>longitude</var>, <var>height</var>) coordinates,
  * {@code PassThroughTransform} can convert the height values from feet to meters without
affecting the latitude and
- * longitude values.</span>
+ * longitude values. Such transform can be built as below:
+ *
+ * {@preformat java
+ *     MathTransform feetToMetres = MathTransforms.linear(0.3048, 0);       // One-dimensional
conversion.
+ *     MathTransform tr = PassThroughTransform.create(2, feetToMetres, 0);  // Three-dimensional
conversion.
+ * }
+ * </div>
+ *
+ * {@section Immutability and thread safety}
+ * {@code PassThroughTransform} is immutable and thread-safe if its {@linkplain #subTransform}
is also
+ * immutable and thread-safe.
+ *
+ * {@section Serialization}
+ * Serialized instances of this class are not guaranteed to be compatible with future SIS
versions.
+ * Serialization should be used only for short term storage or RMI between applications running
the same SIS version.
  *
  * @author  Martin Desruisseaux (IRD, Geomatys)
  * @since   0.5 (derived from geotk-1.2)
@@ -60,16 +74,14 @@ public class PassThroughTransform extend
 
     /**
      * Number of unaffected ordinates after the affected ones.
-     * Always 0 when used through the strict OpenGIS API.
      */
     final int numTrailingOrdinates;
 
     /**
-     * The sub transform.
-     *
-     * @see #getSubTransform()
+     * The sub-transform to apply on the {@linkplain #getModifiedCoordinates() modified coordinates}.
+     * This is often the sub-transform specified at construction time, but not necessarily.
      */
-    final MathTransform subTransform;
+    protected final MathTransform subTransform;
 
     /**
      * The inverse transform. This field will be computed only when needed,
@@ -78,10 +90,13 @@ public class PassThroughTransform extend
     PassThroughTransform inverse;
 
     /**
-     * Creates a pass through transform.
+     * Constructor for sub-classes.
+     * Users should invoke the static {@link #create(int, MathTransform, int)} factory method
instead,
+     * since the most optimal pass-through transform for the given {@code subTransform} is
not necessarily
+     * a {@code PassThroughTransform} instance.
      *
      * @param firstAffectedOrdinate Index of the first affected ordinate.
-     * @param subTransform          The sub transform.
+     * @param subTransform          The sub-transform to apply on modified coordinates.
      * @param numTrailingOrdinates  Number of trailing ordinates to pass through.
      *
      * @see #create(int, MathTransform, int)
@@ -117,9 +132,9 @@ public class PassThroughTransform extend
      * {@code dimTarget - numTrailingOrdinates} exclusive.
      *
      * @param  firstAffectedOrdinate Index of the first affected ordinate.
-     * @param  subTransform          The sub transform.
+     * @param  subTransform          The sub-transform to apply on modified coordinates.
      * @param  numTrailingOrdinates  Number of trailing ordinates to pass through.
-     * @return A pass through transform.
+     * @return A pass-through transform, not necessarily a {@code PassThroughTransform} instance.
      */
     public static MathTransform create(final int firstAffectedOrdinate,
                                        final MathTransform subTransform,
@@ -213,31 +228,8 @@ public class PassThroughTransform extend
     }
 
     /**
-     * Returns the sub transform.
-     *
-     * @return The sub transform.
-     */
-    public final MathTransform getSubTransform() {
-        return subTransform;
-    }
-
-    /**
-     * Ordered sequence of positive integers defining the positions in a coordinate
-     * tuple of the coordinates affected by this pass-through transform. The returned
-     * index are for source coordinates.
-     *
-     * @return The modified coordinates.
-     */
-    public final int[] getModifiedCoordinates() {
-        final int[] index = new int[subTransform.getSourceDimensions()];
-        for (int i=0; i<index.length; i++) {
-            index[i] = i + firstAffectedOrdinate;
-        }
-        return index;
-    }
-
-    /**
-     * Gets the dimension of input points.
+     * Gets the dimension of input points. This the source dimension of the
+     * {@linkplain #subTransform sub-transform} plus the number of pass-through dimensions.
      *
      * @return {@inheritDoc}
      */
@@ -247,7 +239,8 @@ public class PassThroughTransform extend
     }
 
     /**
-     * Gets the dimension of output points.
+     * Gets the dimension of output points. This the target dimension of the
+     * {@linkplain #subTransform sub-transform} plus the number of pass-through dimensions.
      *
      * @return {@inheritDoc}
      */
@@ -257,7 +250,22 @@ public class PassThroughTransform extend
     }
 
     /**
-     * Tests whether this transform does not move any points.
+     * Returns the ordered sequence of positive integers defining the positions in a source
+     * coordinate tuple of the coordinates affected by this pass-through operation.
+     *
+     * @return Indices of the modified source coordinates.
+     */
+    public int[] getModifiedCoordinates() {
+        final int[] index = new int[subTransform.getSourceDimensions()];
+        for (int i=0; i<index.length; i++) {
+            index[i] = i + firstAffectedOrdinate;
+        }
+        return index;
+    }
+
+    /**
+     * Tests whether this transform does not move any points. A {@code PassThroughTransform}
+     * is identity if the {@linkplain #subTransform sub-transform} is also identity.
      *
      * @return {@inheritDoc}
      */
@@ -291,7 +299,7 @@ public class PassThroughTransform extend
     /**
      * Transforms many coordinates in a list of ordinal values.
      *
-     * @throws TransformException If the {@linkplain #getSubTransform() sub-transform} failed.
+     * @throws TransformException If the {@linkplain #subTransform sub-transform} failed.
      */
     @Override
     public void transform(double[] srcPts, int srcOff, final double[] dstPts, int dstOff,
int numPts)
@@ -337,7 +345,7 @@ public class PassThroughTransform extend
     /**
      * Transforms many coordinates in a list of ordinal values.
      *
-     * @throws TransformException If the {@linkplain #getSubTransform() sub-transform} failed.
+     * @throws TransformException If the {@linkplain #subTransform sub-transform} failed.
      */
     @Override
     public void transform(float[] srcPts, int srcOff, final float[] dstPts, int dstOff, int
numPts)
@@ -383,7 +391,7 @@ public class PassThroughTransform extend
     /**
      * Transforms many coordinates in a list of ordinal values.
      *
-     * @throws TransformException If the {@linkplain #getSubTransform() sub-transform} failed.
+     * @throws TransformException If the {@linkplain #subTransform sub-transform} failed.
      */
     @Override
     public void transform(final double[] srcPts, int srcOff, final float[] dstPts, int dstOff,
int numPts)
@@ -407,7 +415,7 @@ public class PassThroughTransform extend
     /**
      * Transforms many coordinates in a list of ordinal values.
      *
-     * @throws TransformException If the {@linkplain #getSubTransform() sub-transform} failed.
+     * @throws TransformException If the {@linkplain #subTransform sub-transform} failed.
      */
     @Override
     public void transform(final float[] srcPts, int srcOff, final double[] dstPts, int dstOff,
int numPts)
@@ -432,7 +440,7 @@ public class PassThroughTransform extend
      * Gets the derivative of this transform at a point.
      *
      * @return {@inheritDoc}
-     * @throws TransformException If the {@linkplain #getSubTransform() sub-transform} failed.
+     * @throws TransformException If the {@linkplain #subTransform sub-transform} failed.
      */
     @Override
     public Matrix derivative(final DirectPosition point) throws TransformException {
@@ -448,7 +456,7 @@ public class PassThroughTransform extend
     }
 
     /**
-     * Creates a pass through transform from a matrix.  This method is invoked when the
+     * Creates a pass-through transform from a matrix.  This method is invoked when the
      * sub-transform can be expressed as a matrix. It is also invoked for computing the
      * matrix returned by {@link #derivative}.
      *
@@ -534,7 +542,7 @@ public class PassThroughTransform extend
      * Creates the inverse transform of this object.
      *
      * @return {@inheritDoc}
-     * @throws NoninvertibleTransformException If the {@linkplain #getSubTransform() sub-transform}
is not invertible.
+     * @throws NoninvertibleTransformException If the {@linkplain #subTransform sub-transform}
is not invertible.
      */
     @Override
     public synchronized MathTransform inverse() throws NoninvertibleTransformException {

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/package-info.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/package-info.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/package-info.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/transform/package-info.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -16,13 +16,30 @@
  */
 
 /**
- * {@code MathTransform} implementations for conversions or transformations of multi-dimensional
coordinate points.
- * A {@code MathTransform} usually performs conversions or transformations from points given
in a
+ * Conversions or transformations of multi-dimensional coordinate points.
+ * {@link org.opengis.referencing.operation.MathTransform} provides a single API for
+ * coordinate conversions or transformations, including map projections.
+ * Each {@code MathTransform} instances can:
+ *
+ * <ul>
+ *   <li>transform a single point,</li>
+ *   <li>transform efficiently an array of coordinates,</li>
+ *   <li>transform a Java2D {@link java.awt.Shape} ({@link org.opengis.referencing.operation.MathTransform2D}
only),</li>
+ *   <li>compute the transform derivative at a location (for advanced users),</li>
+ *   <li>be concatenated in a conversion or transformation chain.</li>
+ * </ul>
+ *
+ * {@code MathTransform} are truly <var>n</var>-dimensional, but specialized
implementations
+ * for 1D and 2D cases are provided for performance reasons or for inter-operability with
Java2D.
+ * In the 2D case, Apache SIS provides instances of the standard {@link java.awt.geom.AffineTransform}
+ * class when possible.
+ *
+ * <p>{@code MathTransform} usually performs conversions or transformations from points
given in a
  * {@linkplain org.apache.sis.referencing.operation.DefaultCoordinateOperation#getSourceCRS()
  * source coordinate reference system} to coordinate values for the same points in the
  * {@linkplain org.apache.sis.referencing.operation.DefaultCoordinateOperation#getTargetCRS()
  * target coordinate reference system}. However the conversions are not necessarily between
CRS;
- * a {@code MathTransform} can also be used for converting the sample values in a raster
for example.
+ * a {@code MathTransform} can also be used for converting the sample values in a raster
for example.</p>
  *
  * <p>This package does not include map projections, which are a special kind of transforms
defined
  * in their own {@linkplain org.apache.sis.referencing.operation.projection projection} package.</p>

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/AbstractMathTransformTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/AbstractMathTransformTest.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/AbstractMathTransformTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/AbstractMathTransformTest.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -19,10 +19,12 @@ package org.apache.sis.referencing.opera
 import java.util.Arrays;
 import java.util.Random;
 import org.opengis.referencing.operation.TransformException;
-import org.apache.sis.test.DependsOnMethod;
-import org.apache.sis.test.DependsOn;
-import org.apache.sis.test.TestCase;
+
+// Test imports
 import org.junit.Test;
+import org.apache.sis.test.TestCase;
+import org.apache.sis.test.DependsOn;
+import org.apache.sis.test.DependsOnMethod;
 
 import static org.junit.Assert.*;
 import static java.lang.StrictMath.*;

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/IterationStrategyTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/IterationStrategyTest.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/IterationStrategyTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/operation/transform/IterationStrategyTest.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -19,9 +19,11 @@ package org.apache.sis.referencing.opera
 import java.util.Arrays;
 import java.util.Random;
 import org.opengis.referencing.operation.TransformException;
-import org.apache.sis.test.DependsOnMethod;
-import org.apache.sis.test.TestCase;
+
+// Test imports
 import org.junit.Test;
+import org.apache.sis.test.TestCase;
+import org.apache.sis.test.DependsOnMethod;
 
 import static org.junit.Assert.*;
 import static java.lang.StrictMath.*;

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/suite/ReferencingTestSuite.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/suite/ReferencingTestSuite.java?rev=1600998&r1=1600997&r2=1600998&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/suite/ReferencingTestSuite.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/suite/ReferencingTestSuite.java
[UTF-8] Fri Jun  6 20:28:52 2014
@@ -42,6 +42,10 @@ import org.junit.BeforeClass;
     org.apache.sis.referencing.operation.matrix.AffineTransforms2DTest.class,
     org.apache.sis.referencing.operation.transform.IterationStrategyTest.class,
     org.apache.sis.referencing.operation.transform.AbstractMathTransformTest.class,
+    org.apache.sis.referencing.operation.transform.ProjectiveTransformTest.class,
+    org.apache.sis.referencing.operation.transform.LinearTransformTest.class,
+    org.apache.sis.referencing.operation.transform.CopyTransformTest.class,
+    org.apache.sis.referencing.operation.transform.PassThroughTransformTest.class,
 
     org.apache.sis.internal.referencing.FormulasTest.class,
     org.apache.sis.internal.referencing.VerticalDatumTypesTest.class,



Mime
View raw message