sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1563988 - in /sis/branches/JDK7/core/sis-referencing/src: main/java/org/apache/sis/io/wkt/Convention.java test/java/org/apache/sis/referencing/Assert.java test/java/org/apache/sis/referencing/crs/HardCodedCRSTest.java
Date Mon, 03 Feb 2014 17:48:25 GMT
Author: desruisseaux
Date: Mon Feb  3 17:48:24 2014
New Revision: 1563988

URL: http://svn.apache.org/r1563988
Log:
Switched the tests to stricter WKT2, and minor javadoc fixes.

Modified:
    sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/io/wkt/Convention.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/Assert.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/crs/HardCodedCRSTest.java

Modified: sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/io/wkt/Convention.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/io/wkt/Convention.java?rev=1563988&r1=1563987&r2=1563988&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/io/wkt/Convention.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/main/java/org/apache/sis/io/wkt/Convention.java
[UTF-8] Mon Feb  3 17:48:24 2014
@@ -55,11 +55,13 @@ import org.apache.sis.metadata.iso.citat
 public enum Convention {
     /**
      * The ISO 19162 format, also known as “WKT 2”.
-     * This is the default convention for all WKT formatting in the Apache SIS library.
      *
-     * <p>Unless otherwise specified by {@link WKTFormat#setNameAuthority(Citation)},
when using
-     * this convention SIS will favor {@linkplain Citations#EPSG EPSG} definitions of projection
-     * and parameter names.</p>
+     * <p>Unless otherwise specified by {@link WKTFormat#setNameAuthority(Citation)},
projections
+     * and parameters formatted with this convention will use the {@linkplain Citations#EPSG
EPSG}
+     * names when available.</p>
+     *
+     * <p>This is the default convention used by {@link FormattableObject#toWKT()}
+     * and for new {@link WKTFormat} instances.</p>
      */
     WKT2(false),
 
@@ -76,8 +78,7 @@ public enum Convention {
      * Those simplifications are allowed by the ISO 19162 standard and do not cause any information
lost.
      * The omitted elements are not needed by Apache SIS WKT parser and often distractive
for the human reader.
      *
-     * <p>By default this simplified format is used by {@link FormattableObject#toString()},
while the stricter
-     * {@link #WKT2} convention is used by {@link FormattableObject#toWKT()}.</p>
+     * <p>This is the default convention used by {@link FormattableObject#toString()}.</p>
      */
     WKT2_SIMPLIFIED(false),
 
@@ -86,9 +87,9 @@ public enum Convention {
      * A definition for this format is shown in Extended Backus Naur Form (EBNF)
      * <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/doc-files/WKT.html">on
GeoAPI</a>.
      *
-     * <p>Unless otherwise specified by {@link WKTFormat#setNameAuthority(Citation)},
when using
-     * this convention SIS will favor {@linkplain Citations#OGC OGC} definitions of projection
-     * and parameter names.</p>
+     * <p>Unless otherwise specified by {@link WKTFormat#setNameAuthority(Citation)},
projections
+     * and parameters formatted with this convention will use the {@linkplain Citations#OGC
OGC}
+     * names when available.</p>
      *
      * {@section Differences compared to WKT 2}
      * WKT 1 and WKT 2 differ in their keywords and syntax, but also in more subtle ways
regarding parameter

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/Assert.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/Assert.java?rev=1563988&r1=1563987&r2=1563988&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/Assert.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/Assert.java
[UTF-8] Mon Feb  3 17:48:24 2014
@@ -30,7 +30,6 @@ import org.opengis.referencing.operation
 import org.opengis.referencing.cs.AxisDirection;
 import org.opengis.referencing.cs.CoordinateSystemAxis;
 import org.opengis.referencing.cs.RangeMeaning;
-import org.apache.sis.io.wkt.Convention;
 import org.apache.sis.io.wkt.Symbols;
 import org.apache.sis.io.wkt.WKTFormat;
 import org.apache.sis.geometry.AbstractEnvelope;
@@ -61,7 +60,6 @@ public strictfp class Assert extends org
      */
     private static final WKTFormat WKT_FORMAT = new WKTFormat(null, null);
     static {
-        WKT_FORMAT.setConvention(Convention.WKT2_SIMPLIFIED);
         final Symbols s = new Symbols(Symbols.SQUARE_BRACKETS);
         s.setPairedQuotes("“”", "\"\"");
         WKT_FORMAT.setSymbols(s);

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/crs/HardCodedCRSTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/crs/HardCodedCRSTest.java?rev=1563988&r1=1563987&r2=1563988&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/crs/HardCodedCRSTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/referencing/crs/HardCodedCRSTest.java
[UTF-8] Mon Feb  3 17:48:24 2014
@@ -78,7 +78,7 @@ public final strictfp class HardCodedCRS
                 "    SPHEROID[“WGS84”, 6378137.0, 298.257223563],\n" +
                 "    AUTHORITY[“EPSG”, “6326”]],\n" +
                 "  PRIMEM[“Greenwich”, 0.0, AUTHORITY[“EPSG”, “8901”]],\n" +
-                "  UNIT[“degree”, 0.017453292519943295],\n" +
+                "  ANGLEUNIT[“degree”, 0.017453292519943295],\n" +
                 "  AXIS[“Geodetic longitude”, EAST],\n" +
                 "  AXIS[“Geodetic latitude”, NORTH],\n" +
                 "  AREA[“World”],\n" +



Mime
View raw message