sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject [sis] 02/04: Rename "polarization" as "polarisation" in two method names for compliance with latest ISO 19115 revision. https://github.com/opengeospatial/geoapi/issues/15
Date Wed, 01 May 2019 15:51:36 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 2492289d6bf3a732d7e09fe3cf3456ba612bf7b4
Author: Martin Desruisseaux <martin.desruisseaux@geomatys.com>
AuthorDate: Wed May 1 15:46:59 2019 +0200

    Rename "polarization" as "polarisation" in two method names for compliance with latest
ISO 19115 revision.
    https://github.com/opengeospatial/geoapi/issues/15
---
 .../org/apache/sis/internal/jaxb/gmi/MI_Band.java  |  4 +--
 .../sis/metadata/iso/content/DefaultBand.java      | 34 +++++++++++-----------
 .../sis/test/xml/AnnotationConsistencyCheck.java   | 12 --------
 3 files changed, 19 insertions(+), 31 deletions(-)

diff --git a/core/sis-metadata/src/main/java/org/apache/sis/internal/jaxb/gmi/MI_Band.java
b/core/sis-metadata/src/main/java/org/apache/sis/internal/jaxb/gmi/MI_Band.java
index ddbb6b2..233cc5c 100644
--- a/core/sis-metadata/src/main/java/org/apache/sis/internal/jaxb/gmi/MI_Band.java
+++ b/core/sis-metadata/src/main/java/org/apache/sis/internal/jaxb/gmi/MI_Band.java
@@ -69,8 +69,8 @@ public class MI_Band extends DefaultBand {
             if (original.getBandBoundaryDefinition()   != null ||
                 original.getNominalSpatialResolution() != null ||
                 original.getTransferFunctionType()     != null ||
-                original.getTransmittedPolarization()  != null ||
-                original.getDetectedPolarization()     != null)
+                original.getTransmittedPolarisation()  != null ||
+                original.getDetectedPolarisation()     != null)
             {
                 return new MI_Band(original);
             }
diff --git a/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/content/DefaultBand.java
b/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/content/DefaultBand.java
index cf1d470..097160d 100644
--- a/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/content/DefaultBand.java
+++ b/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/content/DefaultBand.java
@@ -69,8 +69,8 @@ import static org.apache.sis.internal.metadata.MetadataUtilities.ensurePositive;
     "bandBoundaryDefinition",
     "nominalSpatialResolution",
     "transferFunctionType",
-    "transmittedPolarization",
-    "detectedPolarization"
+    "transmittedPolarisation",
+    "detectedPolarisation"
 })
 @XmlRootElement(name = "MD_Band")
 @XmlSeeAlso(org.apache.sis.internal.jaxb.gmi.MI_Band.class)
@@ -78,7 +78,7 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
     /**
      * Serial number for inter-operability with different versions.
      */
-    private static final long serialVersionUID = -2474871120376144737L;
+    private static final long serialVersionUID = 2492553738885938445L;
 
     /**
      * Shortest wavelength that the sensor is capable of collecting within a designated band.
@@ -113,12 +113,12 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
     /**
      * Polarization of the radiation transmitted.
      */
-    private PolarizationOrientation transmittedPolarization;
+    private PolarizationOrientation transmittedPolarisation;
 
     /**
      * Polarization of the radiation detected.
      */
-    private PolarizationOrientation detectedPolarization;
+    private PolarizationOrientation detectedPolarisation;
 
     /**
      * Constructs an initially empty band.
@@ -151,8 +151,8 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
             peakResponse             = object.getPeakResponse();
             toneGradation            = object.getToneGradation();
             bandBoundaryDefinition   = object.getBandBoundaryDefinition();
-            transmittedPolarization  = object.getTransmittedPolarization();
-            detectedPolarization     = object.getDetectedPolarization();
+            transmittedPolarisation  = object.getTransmittedPolarisation();
+            detectedPolarisation     = object.getDetectedPolarisation();
         }
     }
 
@@ -391,8 +391,8 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
      */
     @Override
     @XmlElement(name = "transmittedPolarisation")
-    public PolarizationOrientation getTransmittedPolarization() {
-        return transmittedPolarization;
+    public PolarizationOrientation getTransmittedPolarisation() {
+        return transmittedPolarisation;
     }
 
     /**
@@ -400,9 +400,9 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
      *
      * @param  newValue  the new transmitted polarization.
      */
-    public void setTransmittedPolarization(final PolarizationOrientation newValue) {
-        checkWritePermission(transmittedPolarization);
-        transmittedPolarization = newValue;
+    public void setTransmittedPolarisation(final PolarizationOrientation newValue) {
+        checkWritePermission(transmittedPolarisation);
+        transmittedPolarisation = newValue;
     }
 
     /**
@@ -412,8 +412,8 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
      */
     @Override
     @XmlElement(name = "detectedPolarisation")
-    public PolarizationOrientation getDetectedPolarization() {
-        return detectedPolarization;
+    public PolarizationOrientation getDetectedPolarisation() {
+        return detectedPolarisation;
     }
 
     /**
@@ -421,8 +421,8 @@ public class DefaultBand extends DefaultSampleDimension implements Band
{
      *
      * @param  newValue  the new detected polarization.
      */
-    public void setDetectedPolarization(final PolarizationOrientation newValue) {
-        checkWritePermission(detectedPolarization);
-        detectedPolarization = newValue;
+    public void setDetectedPolarisation(final PolarizationOrientation newValue) {
+        checkWritePermission(detectedPolarisation);
+        detectedPolarisation = newValue;
     }
 }
diff --git a/core/sis-metadata/src/test/java/org/apache/sis/test/xml/AnnotationConsistencyCheck.java
b/core/sis-metadata/src/test/java/org/apache/sis/test/xml/AnnotationConsistencyCheck.java
index c659824..f6af7fe 100644
--- a/core/sis-metadata/src/test/java/org/apache/sis/test/xml/AnnotationConsistencyCheck.java
+++ b/core/sis-metadata/src/test/java/org/apache/sis/test/xml/AnnotationConsistencyCheck.java
@@ -417,18 +417,6 @@ public abstract strictfp class AnnotationConsistencyCheck extends TestCase
{
                 }
                 break;
             }
-            case "detectedPolarization": {
-                if (org.opengis.metadata.content.Band.class.isAssignableFrom(enclosing))
{
-                    name = "detectedPolarisation";          // Spelling change in XSD files
-                }
-                break;
-            }
-            case "transmittedPolarization": {
-                if (org.opengis.metadata.content.Band.class.isAssignableFrom(enclosing))
{
-                    name = "transmittedPolarisation";       // Spelling change in XSD files
-                }
-                break;
-            }
             case "featureType": {
                 if (org.opengis.metadata.distribution.DataFile.class.isAssignableFrom(enclosing))
{
                     name = "featureTypes";                  // Spelling change in XSD files


Mime
View raw message