This is an automated email from the ASF dual-hosted git repository.

desruisseaux pushed a commit to branch geoapi-3.1
in repository https://gitbox.apache.org/repos/asf/sis.git

commit 883dfe7e9b481d6163c3f483e4b4a8c5eea61c78
Merge: 20ded9bfa1 1182c4c724
Author: Martin Desruisseaux <martin.desruisse...@geomatys.com>
AuthorDate: Thu Apr 18 11:38:35 2024 +0200

    Merge branch 'geoapi-4.0' into geoapi-3.1: removal of non-standard
    PlanarProjection, ConicProjection and CylindricalProjection interfaces.
    
    https://issues.apache.org/jira/browse/SIS-597

 .../org/apache/sis/buildtools/book/OGC.lst         |   1 -
 .../org/apache/sis/portrayal/CanvasContext.java    |   4 +-
 .../gazetteer/MilitaryGridReferenceSystem.java     |   4 +-
 .../sis/referencing/crs/DefaultProjectedCRS.java   |  19 ++--
 .../referencing/factory/sql/EPSGDataAccess.java    |   2 +-
 .../operation/AbstractCoordinateOperation.java     |   3 -
 .../operation/DefaultConicProjection.java          | 108 ---------------------
 .../referencing/operation/DefaultConversion.java   |  41 ++++----
 .../DefaultCoordinateOperationFactory.java         |  15 +--
 .../operation/DefaultCylindricalProjection.java    | 108 ---------------------
 .../operation/DefaultOperationMethod.java          |   5 +-
 .../operation/DefaultPlanarProjection.java         | 108 ---------------------
 .../referencing/operation/DefaultProjection.java   |  13 ++-
 .../apache/sis/referencing/operation/SubTypes.java |  40 +-------
 .../operation/provider/AbstractLambert.java        |   3 +-
 .../operation/provider/AbstractMercator.java       |   3 +-
 .../operation/provider/AbstractStereographic.java  |   3 +-
 .../operation/provider/AlbersEqualArea.java        |   3 +-
 .../provider/AzimuthalEquidistantSpherical.java    |   3 +-
 .../operation/provider/CassiniSoldner.java         |   3 +-
 .../operation/provider/Equirectangular.java        |   4 +-
 .../provider/LambertAzimuthalEqualArea.java        |   3 +-
 .../provider/LambertCylindricalEqualArea.java      |   3 +-
 .../LambertCylindricalEqualAreaSpherical.java      |   3 +-
 .../operation/provider/MapProjection.java          |   9 +-
 .../provider/ModifiedAzimuthalEquidistant.java     |   3 +-
 .../referencing/operation/provider/Mollweide.java  |   3 +-
 .../operation/provider/Orthographic.java           |   3 +-
 .../referencing/operation/provider/Polyconic.java  |   3 +-
 .../operation/provider/SatelliteTracking.java      |   3 +-
 .../referencing/operation/provider/Sinusoidal.java |   3 +-
 .../org/apache/sis/geometry/TransformTestCase.java |  15 +--
 .../sis/io/wkt/GeodeticObjectParserTest.java       |   4 +-
 .../referencing/crs/DefaultProjectedCRSTest.java   |   4 +-
 .../referencing/factory/sql/EPSGFactoryTest.java   |   3 +-
 .../transform/OperationMethodSetTest.java          |  52 +++++-----
 .../report/CoordinateOperationMethods.java         |  19 ++--
 .../report/CoordinateReferenceSystems.java         |   2 +-
 .../integration/CoordinateReferenceSystemTest.java |   6 +-
 .../sis/storage/geotiff/reader/CRSBuilder.java     |   4 +-
 geoapi/snapshot                                    |   2 +-
 41 files changed, 117 insertions(+), 523 deletions(-)

diff --cc 
endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java
index 1202bad9c7,0a69f68c58..d2bfb89b47
--- 
a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java
+++ 
b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java
@@@ -23,7 -23,7 +23,8 @@@ import jakarta.xml.bind.annotation.XmlR
  import javax.measure.Unit;
  import javax.measure.quantity.Angle;
  import org.opengis.referencing.crs.ProjectedCRS;
 +import org.opengis.referencing.crs.GeographicCRS;
+ import org.opengis.referencing.crs.GeodeticCRS;
  import org.opengis.referencing.cs.CartesianCS;
  import org.opengis.referencing.cs.CoordinateSystem;                 // For 
javadoc
  import org.opengis.referencing.datum.GeodeticDatum;
diff --cc 
endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultCoordinateOperationFactory.java
index b4f4c42b55,bbf45d2eef..1903225188
--- 
a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultCoordinateOperationFactory.java
+++ 
b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultCoordinateOperationFactory.java
@@@ -593,17 -592,7 +592,7 @@@ next:   for (int i=components.size(); -
                  throw new IllegalArgumentException(Errors.format(
                          Errors.Keys.ForbiddenAttribute_2, "interpolationCRS", 
baseType));
              }
-             final GeographicCRS baseCRS = (GeographicCRS) sourceCRS;
-             final ProjectedCRS  crs     =  (ProjectedCRS) targetCRS;
-             if (CylindricalProjection.class.isAssignableFrom(baseType)) {
-                 op = new DefaultCylindricalProjection(properties, baseCRS, 
crs, method, transform);
-             } else if (ConicProjection.class.isAssignableFrom(baseType)) {
-                 op = new DefaultConicProjection(properties, baseCRS, crs, 
method, transform);
-             } else if (PlanarProjection.class.isAssignableFrom(baseType)) {
-                 op = new DefaultPlanarProjection(properties, baseCRS, crs, 
method, transform);
-             } else {
-                 op = new DefaultProjection(properties, baseCRS, crs, method, 
transform);
-             }
 -            op = new DefaultProjection(properties, (GeodeticCRS) sourceCRS, 
(ProjectedCRS) targetCRS, method, transform);
++            op = new DefaultProjection(properties, (GeographicCRS) sourceCRS, 
(ProjectedCRS) targetCRS, method, transform);
          } else if (Conversion.class.isAssignableFrom(baseType)) {
              op = new DefaultConversion(properties, sourceCRS, targetCRS, 
interpolationCRS, method, transform);
          } else {  // See above comment about this last-resort fallback.
diff --cc 
endorsed/src/org.apache.sis.referencing/test/org/apache/sis/test/integration/CoordinateReferenceSystemTest.java
index 8ef6919d9e,8e1fc77d72..9f0731a943
--- 
a/endorsed/src/org.apache.sis.referencing/test/org/apache/sis/test/integration/CoordinateReferenceSystemTest.java
+++ 
b/endorsed/src/org.apache.sis.referencing/test/org/apache/sis/test/integration/CoordinateReferenceSystemTest.java
@@@ -65,14 -65,14 +65,14 @@@ public final class CoordinateReferenceS
      public void testDerivedCRS() throws FactoryException {
          assertTrue(TestFactorySource.getSharedFactory() != null);
          CoordinateReferenceSystem crs = CRS.forCode("EPSG:5820");
 -        assertInstanceOf(DerivedCRS  .class, crs);
 -        assertInstanceOf(ProjectedCRS.class, crs);
 -        assertInstanceOf(CartesianCS .class, crs.getCoordinateSystem());
 -        assertInstanceOf(CartesianCS .class, ((DerivedCRS) 
crs).getBaseCRS().getCoordinateSystem());
 +        assertInstanceOf(DerivedCRS .class, crs);
 +        assertInstanceOf(GeodeticCRS.class, crs);
 +        assertInstanceOf(CartesianCS.class, crs.getCoordinateSystem());
 +        assertInstanceOf(CartesianCS.class, ((DerivedCRS) 
crs).getBaseCRS().getCoordinateSystem());
          /*
-          * Some tests are disabled because `EPSGDataAccess` confuse this 
derived CRS
-          * with a projected CRS. We are waiting for upgrade to EPSG database 
10+
-          * before to re-evaluate how to fix this issue.
+          * Some tests are disabled because `EPSGDataAccess` confuses CRS type.
+          * We are waiting for upgrade to EPSG database 10+ before to 
re-evaluate
+          * how to fix this issue.
           *
           * https://issues.apache.org/jira/browse/SIS-518
           */
diff --cc geoapi/snapshot
index 10bab8acc3,b822d026bd..b6f55a7306
--- a/geoapi/snapshot
+++ b/geoapi/snapshot
@@@ -1,1 -1,1 +1,1 @@@
- Subproject commit 10bab8acc33a58679276befe17b26e89c7b333b8
 -Subproject commit b822d026bd9e4692a159a9bd2bc158716da2e721
++Subproject commit b6f55a7306de16494d1d9c49c91be18a2438dc0e

Reply via email to