sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1697417 - in /sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis: internal/referencing/PositionalAccuracyConstant.java referencing/operation/DefaultConcatenatedOperation.java
Date Mon, 24 Aug 2015 14:46:59 GMT
Author: desruisseaux
Date: Mon Aug 24 14:46:58 2015
New Revision: 1697417

URL: http://svn.apache.org/r1697417
Log:
Update for GeoAPI change: CoordinateOperation.getOperations() returns list of CoordinateOperation
instead than SingleOperation.
This is an upgrade from ISO 19111:2003 model to ISO 19111:2007 model.

Modified:
    sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/PositionalAccuracyConstant.java
    sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java

Modified: sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/PositionalAccuracyConstant.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/PositionalAccuracyConstant.java?rev=1697417&r1=1697416&r2=1697417&view=diff
==============================================================================
--- sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/PositionalAccuracyConstant.java
[UTF-8] (original)
+++ sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/PositionalAccuracyConstant.java
[UTF-8] Mon Aug 24 14:46:58 2015
@@ -32,7 +32,6 @@ import org.opengis.metadata.quality.Resu
 import org.opengis.referencing.operation.ConcatenatedOperation;
 import org.opengis.referencing.operation.Conversion;
 import org.opengis.referencing.operation.CoordinateOperation;
-import org.opengis.referencing.operation.SingleOperation;
 import org.opengis.referencing.operation.Transformation;
 import org.apache.sis.measure.Units;
 import org.apache.sis.metadata.iso.citation.Citations;
@@ -204,7 +203,7 @@ public final class PositionalAccuracyCon
          */
         double accuracy = Double.NaN;
         if (operation instanceof ConcatenatedOperation) {
-            for (final SingleOperation op : ((ConcatenatedOperation) operation).getOperations())
{
+            for (final CoordinateOperation op : ((ConcatenatedOperation) operation).getOperations())
{
                 final double candidate = Math.abs(getLinearAccuracy(op));
                 if (!Double.isNaN(candidate)) {
                     if (Double.isNaN(accuracy)) {

Modified: sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java?rev=1697417&r1=1697416&r2=1697417&view=diff
==============================================================================
--- sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java
[UTF-8] (original)
+++ sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java
[UTF-8] Mon Aug 24 14:46:58 2015
@@ -65,7 +65,7 @@ final class DefaultConcatenatedOperation
     /**
      * The sequence of operations.
      */
-    private final List<SingleOperation> operations;
+    private final List<? extends CoordinateOperation> operations;
 
     /**
      * Constructs a concatenated operation from a set of properties and a
@@ -164,7 +164,7 @@ final class DefaultConcatenatedOperation
                 target.add((SingleOperation) op);
             } else if (op instanceof ConcatenatedOperation) {
                 final ConcatenatedOperation cop = (ConcatenatedOperation) op;
-                final List<SingleOperation> cops = cop.getOperations();
+                final List<? extends CoordinateOperation> cops = cop.getOperations();
                 expand(properties, cops.toArray(new CoordinateOperation[cops.size()]), target,
factory, false);
             } else {
                 throw new IllegalArgumentException(Errors.getResources(properties).getString(
@@ -308,7 +308,8 @@ final class DefaultConcatenatedOperation
      * @return The sequence of operations.
      */
     @Override
-    public List<SingleOperation> getOperations() {
+    @SuppressWarnings("ReturnOfCollectionOrArrayField")
+    public List<? extends CoordinateOperation> getOperations() {
         return operations;
     }
 



Mime
View raw message