Author: desruisseaux
Date: Tue Mar 24 15:07:00 2015
New Revision: 1668916

URL: http://svn.apache.org/r1668916
Log:
Minor constant declaration and renaming for sharing existing methods.

Modified:
    
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MapProjection.java
    
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator1SP.java
    
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator2SP.java
    
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MillerCylindrical.java
    
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/PseudoMercator.java
    
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.java
    
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.properties
    
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages_fr.properties

Modified: 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MapProjection.java
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MapProjection.java?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MapProjection.java
 [UTF-8] (original)
+++ 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MapProjection.java
 [UTF-8] Tue Mar 24 15:07:00 2015
@@ -197,7 +197,7 @@ public abstract class MapProjection exte
      * @param origin The name of the projection for where the parameter is 
formally used.
      * @param usedIn The name of the projection where we also use that 
parameter.
      */
-    static InternationalString notFormallyEPSG(final String origin, final 
String usedIn) {
-        return 
Messages.formatInternational(Messages.Keys.NotFormallyAnEpsgParameter_2, 
origin, usedIn);
+    static InternationalString notFormalParameter(final String origin, final 
String usedIn) {
+        return 
Messages.formatInternational(Messages.Keys.NotFormalProjectionParameter_2, 
origin, usedIn);
     }
 }

Modified: 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator1SP.java
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator1SP.java?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator1SP.java
 [UTF-8] (original)
+++ 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator1SP.java
 [UTF-8] Tue Mar 24 15:07:00 2015
@@ -45,6 +45,11 @@ public final class Mercator1SP extends M
     private static final long serialVersionUID = -5886510621481710072L;
 
     /**
+     * The name of this projection method.
+     */
+    static final String NAME = "Mercator (variant A)";
+
+    /**
      * The operation parameter descriptor for the <cite>Latitude of natural 
origin</cite> parameter value.
      * Valid values range is (-90 … 90)° and default value is 0°.
      */
@@ -117,13 +122,13 @@ public final class Mercator1SP extends M
                 .addName(Citations.PROJ4,   "y_0"));
 
         PARAMETERS = builder
-            .addIdentifier(             "9804")                                
                 // The ellipsoidal case
-            .addIdentifier(             "1026")                                
                 // The spherical case
-            .addDeprecatedIdentifier(   "9841", "1026")                        
                 // The spherical (1SP) case
-            .addName(                   "Mercator (variant A)")                
                 // Starting from EPSG version 7.6
-            .addName(                   "Mercator (Spherical)")                
                 // Starting from EPSG version 7.6
-            .addDeprecatedName(         "Mercator (1SP)",             
"Mercator (variant A)")   // Prior to EPSG version 7.6
-            .addDeprecatedName(         "Mercator (1SP) (Spherical)", 
"Mercator (Spherical)")   // Prior to EPSG version 7.6
+            .addIdentifier(             "9804")                                
                   // The ellipsoidal case
+            .addIdentifier(             "1026")                                
                   // The spherical case
+            .addDeprecatedIdentifier(   "9841", "1026")                        
                   // The spherical (1SP) case
+            .addName(NAME            /* "Mercator (variant A)" */)             
                   // Starting from EPSG version 7.6
+            .addName(                   "Mercator (Spherical)")                
                   // Starting from EPSG version 7.6
+            .addDeprecatedName(         "Mercator (1SP)", NAME     /* 
"Mercator (variant A)" */)  // Prior to EPSG version 7.6
+            .addDeprecatedName(         "Mercator (1SP) (Spherical)", 
"Mercator (Spherical)")     // Prior to EPSG version 7.6
             .addName(Citations.OGC,     "Mercator_1SP")
             .addName(Citations.GEOTIFF, "CT_Mercator")
             .addName(Citations.PROJ4,   "merc")

Modified: 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator2SP.java
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator2SP.java?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator2SP.java
 [UTF-8] (original)
+++ 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/Mercator2SP.java
 [UTF-8] Tue Mar 24 15:07:00 2015
@@ -115,7 +115,7 @@ public final class Mercator2SP extends M
          * of the "Mercator (variant B)" projection according EPSG. But we 
declare them
          * as optional parameters because they are sometime used.
          */
-        final InternationalString remarks = notFormallyEPSG("Mercator (variant 
A)", "Mercator (variant B)");
+        final InternationalString remarks = 
notFormalParameter(Mercator1SP.NAME, "Mercator (variant B)");
         LATITUDE_OF_ORIGIN = 
createLatitude(withEsriAndNetcdf(Mercator1SP.LATITUDE_OF_ORIGIN, builder,
                 "Latitude_Of_Origin", 
"latitude_of_projection_origin").setRequired(false).setRemarks(remarks), false);
 

Modified: 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MillerCylindrical.java
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MillerCylindrical.java?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MillerCylindrical.java
 [UTF-8] (original)
+++ 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/MillerCylindrical.java
 [UTF-8] Tue Mar 24 15:07:00 2015
@@ -63,6 +63,11 @@ public class MillerCylindrical extends M
     private static final long serialVersionUID = -7682370461334391883L;
 
     /**
+     * The name of this operation method.
+     */
+    public static final String NAME = "Miller_Cylindrical";
+
+    /**
      * The group of all parameters expected by this coordinate operation.
      */
     public static final ParameterDescriptorGroup PARAMETERS;
@@ -85,12 +90,12 @@ public class MillerCylindrical extends M
          * The scale factor is not formally a parameter of the "Miller 
Cylindrical" projection.
          * But we declare it as an optional parameters because it is sometime 
used.
          */
-        final InternationalString remarks = notFormallyEPSG("Mercator (variant 
A)", "Miller Cylindrical");
+        final InternationalString remarks = 
notFormalParameter(Mercator1SP.NAME, "Miller Cylindrical");
         final ParameterDescriptor<?> scaleFactor = 
createScale(exceptEPSG(Mercator1SP.SCALE_FACTOR, builder)
                 .setRemarks(remarks).setRequired(false));
 
         PARAMETERS = builder
-            .addName      (                    "Miller_Cylindrical")
+            .addName      (NAME)
             .addName      (Citations.GEOTIFF,  "CT_MillerCylindrical")
             .addIdentifier(Citations.GEOTIFF,  "20")
             .addName      (Citations.PROJ4,    "mill")

Modified: 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/PseudoMercator.java
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/PseudoMercator.java?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/PseudoMercator.java
 [UTF-8] (original)
+++ 
sis/branches/JDK8/core/sis-referencing/src/main/java/org/apache/sis/internal/referencing/provider/PseudoMercator.java
 [UTF-8] Tue Mar 24 15:07:00 2015
@@ -63,7 +63,7 @@ public final class PseudoMercator extend
          * The scale factor is not formally a parameter of the "Popular 
Visualisation Pseudo Mercator" projection
          * according EPSG. But we declare it as an optional parameters because 
it is sometime used.
          */
-        final InternationalString remarks = notFormallyEPSG("Mercator (variant 
A)", "Pseudo Mercator");
+        final InternationalString remarks = 
notFormalParameter(Mercator1SP.NAME, "Pseudo Mercator");
         final ParameterDescriptor<?> scaleFactor = 
createScale(withEsriAndNetcdf(Mercator1SP.SCALE_FACTOR, builder,
                 "Scale_Factor", 
"scale_factor_at_projection_origin").setRemarks(remarks).setRequired(false));
 

Modified: 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.java
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.java?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.java
 [UTF-8] (original)
+++ 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.java
 [UTF-8] Tue Mar 24 15:07:00 2015
@@ -100,7 +100,7 @@ public final class Messages extends Inde
         /**
          * This parameter borrowed from the “{0}” projection is not formally a 
“{1}” parameter.
          */
-        public static final short NotFormallyAnEpsgParameter_2 = 10;
+        public static final short NotFormalProjectionParameter_2 = 10;
 
         /**
          * Property “{0}” is hidden by “{1}”.

Modified: 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.properties
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.properties?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.properties
 [ISO-8859-1] (original)
+++ 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages.properties
 [ISO-8859-1] Tue Mar 24 15:07:00 2015
@@ -23,5 +23,5 @@ IgnoredPropertyAssociatedTo_1   = Ignore
 PropertyHiddenBy_2              = Property \u201c{0}\u201d is hidden by 
\u201c{1}\u201d.
 LocalesDiscarded                = Text were discarded for some locales.
 MismatchedEllipsoidAxisLength_3 = The \u201c{1}\u201d parameter could have 
been omitted. But it has been given a value of {2} which does not match the 
definition of the \u201c{0}\u201d ellipsoid.
-NotFormallyAnEpsgParameter_2    = This parameter borrowed from the 
\u201c{0}\u201d projection is not formally a \u201c{1}\u201d parameter.
+NotFormalProjectionParameter_2  = This parameter borrowed from the 
\u201c{0}\u201d projection is not formally a \u201c{1}\u201d parameter.
 UnparsableValueStoredAsText_2   = Can not parse \u201c{1}\u201d as an instance 
of \u2018{0}\u2019. The value is stored as plain text instead, but will be 
ignored by some processing.

Modified: 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages_fr.properties
URL: 
http://svn.apache.org/viewvc/sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages_fr.properties?rev=1668916&r1=1668915&r2=1668916&view=diff
==============================================================================
--- 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages_fr.properties
 [ISO-8859-1] (original)
+++ 
sis/branches/JDK8/core/sis-utility/src/main/java/org/apache/sis/util/resources/Messages_fr.properties
 [ISO-8859-1] Tue Mar 24 15:07:00 2015
@@ -23,5 +23,5 @@ IgnoredPropertyAssociatedTo_1   = Une pr
 PropertyHiddenBy_2              = La propri\u00e9t\u00e9 
\u00ab\u202f{0}\u202f\u00bb est masqu\u00e9e par \u00ab\u202f{1}\u202f\u00bb.
 LocalesDiscarded                = Des textes ont \u00e9t\u00e9 ignor\u00e9s 
pour certaines langues.
 MismatchedEllipsoidAxisLength_3 = Le param\u00e8tre 
\u00ab\u202f{1}\u202f\u00bb aurait pu \u00eatre omis. Mais il lui a 
\u00e9t\u00e9 donn\u00e9 la valeur {2} qui ne correspond pas \u00e0 la 
d\u00e9finition de l\u2019ellipso\u00efde \u00ab\u202f{0}\u202f\u00bb.
-NotFormallyAnEpsgParameter_2    = Ce param\u00e8tre emprunt\u00e9 \u00e0 la 
projection \u00ab\u202f{0}\u202f\u00bb n\u2019est pas formellement un 
param\u00e8tre de \u00ab\u202f{1}\u202f\u00bb.
+NotFormalProjectionParameter_2  = Ce param\u00e8tre emprunt\u00e9 \u00e0 la 
projection \u00ab\u202f{0}\u202f\u00bb n\u2019est pas formellement un 
param\u00e8tre de \u00ab\u202f{1}\u202f\u00bb.
 UnparsableValueStoredAsText_2   = La valeur \u00ab\u202f{1}\u202f\u00bb ne 
peut pas \u00eatre interpr\u00e9t\u00e9e comme une instance de \u2018{0}\u2019. 
Elle est donc m\u00e9moris\u00e9e sous sa forme textuelle, mais sera 
ignor\u00e9e par certains traitements.


Reply via email to