sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject [sis] 03/04: Replace hard-coded string value by the constant provided by UCAR library.
Date Tue, 04 Jun 2019 09:53:58 GMT
This is an automated email from the ASF dual-hosted git repository.

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

commit f79abf8ef4913d3ad7c60b0dab8106faad4efe23
Author: Martin Desruisseaux <martin.desruisseaux@geomatys.com>
AuthorDate: Mon Jun 3 17:42:29 2019 +0200

    Replace hard-coded string value by the constant provided by UCAR library.
---
 profiles/sis-japan-profile/pom.xml                      | 17 +++++++++++++++++
 .../org/apache/sis/internal/earth/netcdf/GCOM_C.java    |  3 ++-
 2 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/profiles/sis-japan-profile/pom.xml b/profiles/sis-japan-profile/pom.xml
index 1156ee1..3fcb8f6 100644
--- a/profiles/sis-japan-profile/pom.xml
+++ b/profiles/sis-japan-profile/pom.xml
@@ -104,6 +104,23 @@
       <artifactId>sis-netcdf</artifactId>
       <version>${project.version}</version>
     </dependency>
+    <dependency>
+      <groupId>edu.ucar</groupId>
+      <artifactId>cdm</artifactId>
+      <optional>true</optional>
+    </dependency>
   </dependencies>
 
+  <!--  UCAR repository from which to download the netCDF library. -->
+  <repositories>
+    <repository>
+      <id>UCAR</id>
+      <name>UCAR repository</name>
+      <url>https://artifacts.unidata.ucar.edu/repository/unidata-releases</url>
+      <snapshots>
+        <enabled>false</enabled>
+      </snapshots>
+    </repository>
+  </repositories>
+
 </project>
diff --git a/profiles/sis-japan-profile/src/main/java/org/apache/sis/internal/earth/netcdf/GCOM_C.java
b/profiles/sis-japan-profile/src/main/java/org/apache/sis/internal/earth/netcdf/GCOM_C.java
index 477e799..b74c9c4 100644
--- a/profiles/sis-japan-profile/src/main/java/org/apache/sis/internal/earth/netcdf/GCOM_C.java
+++ b/profiles/sis-japan-profile/src/main/java/org/apache/sis/internal/earth/netcdf/GCOM_C.java
@@ -40,6 +40,7 @@ import org.apache.sis.referencing.operation.transform.MathTransforms;
 import org.apache.sis.referencing.operation.matrix.Matrix3;
 import org.apache.sis.referencing.CommonCRS;
 import org.apache.sis.measure.NumberRange;
+import ucar.nc2.constants.CF;
 
 
 /**
@@ -346,7 +347,7 @@ public final class GCOM_C extends Convention {
             return super.projection(node);
         }
         final Map<String,Object> definition = new HashMap<>(4);
-        definition.put("grid_mapping_name", method);
+        definition.put(CF.GRID_MAPPING_NAME, method);
         definition.put(CONVERSION_NAME, name);
         return definition;
     }


Mime
View raw message