sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1785905 [4/5] - in /sis/trunk: ./ application/sis-console/src/main/java/org/apache/sis/console/ core/ core/sis-feature/src/main/java/org/apache/sis/feature/ core/sis-metadata/src/main/java/org/apache/sis/internal/metadata/ core/sis-metadat...
Date Tue, 07 Mar 2017 23:37:50 GMT
Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/internal/util/MetadataServices.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/internal/util/MetadataServices.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/internal/util/MetadataServices.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/internal/util/MetadataServices.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -16,7 +16,9 @@
  */
 package org.apache.sis.internal.util;
 
+import java.text.Format;
 import java.util.Locale;
+import java.util.TimeZone;
 import org.opengis.metadata.citation.Citation;
 import org.apache.sis.internal.simple.CitationConstant;
 import org.apache.sis.internal.system.Modules;
@@ -30,7 +32,7 @@ import org.apache.sis.internal.system.Op
  *
  * @author  Martin Desruisseaux (Geomatys)
  * @since   0.6
- * @version 0.7
+ * @version 0.8
  * @module
  */
 public class MetadataServices extends OptionalDependency {
@@ -132,4 +134,17 @@ public class MetadataServices extends Op
     public String getInformation(String key, Locale locale) {
         return null;
     }
+
+    /**
+     * Creates a format for {@link org.opengis.geometry.DirectPosition} instances.
+     *
+     * @param  locale    the locale for the new {@code Format}, or {@code null} for {@code Locale.ROOT}.
+     * @param  timezone  the timezone, or {@code null} for UTC.
+     * @return a {@link org.apache.sis.geometry.CoordinateFormat}.
+     *
+     * @since 0.8
+     */
+    public Format createCoordinateFormat(final Locale locale, final TimeZone timezone) {
+        throw moduleNotFound();
+    }
 }

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/CompoundFormat.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/CompoundFormat.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/CompoundFormat.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/CompoundFormat.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -32,6 +32,7 @@ import java.text.SimpleDateFormat;
 import javax.measure.Unit;
 
 import org.opengis.referencing.IdentifiedObject;
+import org.opengis.geometry.DirectPosition;
 import org.apache.sis.measure.Angle;
 import org.apache.sis.measure.AngleFormat;
 import org.apache.sis.measure.Range;
@@ -40,6 +41,7 @@ import org.apache.sis.measure.UnitFormat
 import org.apache.sis.util.Localized;
 import org.apache.sis.util.ArraysExt;
 import org.apache.sis.util.ArgumentChecks;
+import org.apache.sis.internal.util.MetadataServices;
 import org.apache.sis.internal.util.LocalizedParseException;
 
 import static org.apache.sis.internal.util.StandardDateFormat.UTC;
@@ -54,22 +56,38 @@ import org.apache.sis.internal.jdk8.Unch
  * large blocks of data, for example a metadata tree or a <cite>Well Known Text</cite> (WKT).
  * Those blocks of data usually contain smaller elements like numbers and dates, whose parsing
  * and formatting can be delegated to {@link NumberFormat} and {@link DateFormat} respectively.
+ * Subclasses can obtain instances of those formats by call to {@link #getFormat(Class)} where
+ * the argument is the type of the value to parse or format.
+ * {@code CompoundFormat} supports at least the following value types, but subclasses may add more types:
  *
- * <p>Since {@code CompoundFormat} may work on larger texts than the usual {@code Format} classes,
+ * <table class="sis">
+ *   <caption>Supported value types</caption>
+ *   <tr><th>Value type</th>              <th>Format type</th>                                      <th>Remarks</th></tr>
+ *   <tr><td>{@link DirectPosition}</td>  <td>{@link org.apache.sis.geometry.CoordinateFormat}</td> <td>Requires {@code sis-referencing} module.</td></tr>
+ *   <tr><td>{@link Angle}</td>           <td>{@link AngleFormat}</td>                              <td></td></tr>
+ *   <tr><td>{@link Date}</td>            <td>{@link DateFormat}</td>                               <td>Timezone specified by {@link #getTimeZone()}.</td></tr>
+ *   <tr><td>{@link Number}</td>          <td>{@link NumberFormat}</td>                             <td></td></tr>
+ *   <tr><td>{@link Unit}</td>            <td>{@link UnitFormat}</td>                               <td></td></tr>
+ *   <tr><td>{@link Range}</td>           <td>{@link RangeFormat}</td>                              <td></td></tr>
+ *   <tr><td>{@link Class}</td>           <td>(internal)</td>                                       <td></td></tr>
+ * </table>
+ *
+ * <div class="section">Sources and destinations</div>
+ * Since {@code CompoundFormat} may work on larger texts than the usual {@code Format} classes,
  * it defines {@code parse} and {@code format} methods working with arbitrary {@link CharSequence}
  * and {@link Appendable} instances. The standard {@code Format} methods redirect to the above-cited
- * methods.</p>
- *
- * <p>The abstract methods to be defined by subclasses are:</p>
+ * methods.
  *
+ * <div class="section">Sub-classing</div>
+ * The abstract methods to be defined by subclasses are:
  * <ul>
- *   <li>{@link #getValueType()} returns the {@code <T>} class or a subclass.</li>
- *   <li>{@link #parse(CharSequence, ParsePosition)} may throws {@code ParseException}.</li>
- *   <li>{@link #format(Object, Appendable)} may throws {@code IOException}.</li>
+ *   <li>{@link #getValueType()}</li>
+ *   <li>{@link #format(Object, Appendable)}</li>
+ *   <li>{@link #parse(CharSequence, ParsePosition)}</li>
  * </ul>
  *
  * <div class="note"><b>API note:</b>
- * In the standard {@link Format} class, the {@code parse} methods either accept a {@link ParsePosition} argument
+ * in the standard {@link Format} class, the {@code parse} methods either accept a {@link ParsePosition} argument
  * and returns {@code null} on error, or does not take position argument and throws a {@link ParseException} on error.
  * In this {@code CompoundFormat} class, the {@code parse} method both takes a {@code ParsePosition} argument and
  * throws a {@code ParseException} on error. This allows both substring parsing and more accurate exception message
@@ -213,13 +231,14 @@ public abstract class CompoundFormat<T>
      *     <ul>
      *       <li>this method returns {@code null}, or</li>
      *       <li>a {@code ParseException} is thrown with an {@linkplain ParseException#getErrorOffset() error offset}
-     *           set to the index of the first unparsable character. This is usually the same information than the
-     *           above-cited {@code pos} error index, but implementations are free to adopt a slightly different policy.</li>
+     *           set to the index of the first unparsable character.</li>
      *     </ul>
      *   </li>
      * </ul>
      *
-     * <div class="note"><b>Example:</b>
+     * <div class="note"><b>Note:</b>
+     * if a {@code ParseException} is thrown, its error offset is usually the same than the {@code ParsePosition}
+     * error index, but implementations are free to adopt a slightly different policy. For example
      * if parsing of the {@code "30.0 40,0"} coordinate fails on the coma in the last number, then the {@code pos}
      * {@linkplain ParsePosition#getErrorIndex() error index} may be set to 5 (the beginning of the {@code "40.0"}
      * character sequence) or to 7 (the coma position), depending on the implementation.</div>
@@ -230,6 +249,7 @@ public abstract class CompoundFormat<T>
      *
      * @param  text  the character sequence for the object to parse.
      * @param  pos   the position where to start the parsing.
+     *               On return, the position where the parsing stopped or where an error occurred.
      * @return the parsed object, or {@code null} if the text is not recognized.
      * @throws ParseException if an error occurred while parsing the object.
      */
@@ -399,18 +419,18 @@ public abstract class CompoundFormat<T>
      * Creates a new format to use for parsing and formatting values of the given type.
      * This method is invoked by {@link #getFormat(Class)} the first time that a format
      * is needed for the given type.
-     *
-     * <p>The default implementation creates the following formats:</p>
+     * The class given in argument can be any of the classes listed in the "Value type" column below:
      *
      * <table class="sis">
-     *   <caption>Supported formats by type</caption>
-     *   <tr><th>Value type</th>     <th>Format</th></tr>
-     *   <tr><td>{@link Angle}</td>  <td>{@link AngleFormat}</td></tr>
-     *   <tr><td>{@link Date}</td>   <td>{@link DateFormat}</td></tr>
-     *   <tr><td>{@link Number}</td> <td>{@link NumberFormat}</td></tr>
-     *   <tr><td>{@link Unit}</td>   <td>{@link UnitFormat}</td></tr>
-     *   <tr><td>{@link Range}</td>  <td>{@link RangeFormat}</td></tr>
-     *   <tr><td>{@link Class}</td>  <td>(internal)</td></tr>
+     *   <caption>Supported value types</caption>
+     *   <tr><th>Value type</th>              <th>Format type</th></tr>
+     *   <tr><td>{@link DirectPosition}</td>  <td>{@link org.apache.sis.geometry.CoordinateFormat}</td></tr>
+     *   <tr><td>{@link Angle}</td>           <td>{@link AngleFormat}</td></tr>
+     *   <tr><td>{@link Date}</td>            <td>{@link DateFormat}</td></tr>
+     *   <tr><td>{@link Number}</td>          <td>{@link NumberFormat}</td></tr>
+     *   <tr><td>{@link Unit}</td>            <td>{@link UnitFormat}</td></tr>
+     *   <tr><td>{@link Range}</td>           <td>{@link RangeFormat}</td></tr>
+     *   <tr><td>{@link Class}</td>           <td>(internal)</td></tr>
      * </table>
      *
      * Subclasses can override this method for adding more types, or for configuring the
@@ -453,6 +473,8 @@ public abstract class CompoundFormat<T>
             return new UnitFormat(locale);
         } else if (valueType == Range.class) {
             return new RangeFormat(locale);
+        } else if (valueType == DirectPosition.class) {
+            return MetadataServices.getInstance().createCoordinateFormat(locale, getTimeZone());
         } else if (valueType == Class.class) {
             return ClassFormat.INSTANCE;
         } else {

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/TableAppender.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/TableAppender.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/TableAppender.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/io/TableAppender.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -42,8 +42,7 @@ import static org.apache.sis.util.Charac
  * <p>For example, the following code:</p>
  *
  * {@preformat java
- *     StringBuilder  buffer = new StringBuilder();
- *     TableAppender table  = new TableAppender(buffer);
+ *     TableAppender table = new TableAppender(System.out);
  *     table.nextLine('═');
  *     table.append("English\tFrench\tr.e.d.\n");
  *     table.nextLine('-');
@@ -70,7 +69,7 @@ import static org.apache.sis.util.Charac
  *
  * @author  Martin Desruisseaux (MPO, IRD, Geomatys)
  * @since   0.3
- * @version 0.3
+ * @version 0.8
  * @module
  *
  * @see org.apache.sis.util.collection.TreeTableFormat
@@ -264,6 +263,26 @@ public class TableAppender extends Appen
     }
 
     /**
+     * Creates a new table formatter writing in the given output with the specified column separator and border.
+     *
+     * @param out          the underlying stream or buffer to write to.
+     * @param leftBorder   string to write on the left side of the table.
+     * @param separator    string to write between columns.
+     * @param rightBorder  string to write on the right side of the table.
+     *
+     * @since 0.8
+     */
+    public TableAppender(final Appendable out, final String leftBorder, final String separator, final String rightBorder) {
+        super(out);
+        ArgumentChecks.ensureNonNull("leftBorder",  leftBorder);
+        ArgumentChecks.ensureNonNull("separator",   separator);
+        ArgumentChecks.ensureNonNull("rightBorder", rightBorder);
+        this.leftBorder      = leftBorder;
+        this.rightBorder     = rightBorder;
+        this.columnSeparator = separator;
+    }
+
+    /**
      * Writes a border or a corner to the underlying stream or buffer.
      *
      * @param  horizontalBorder -1 for left border, +1 for right border,  0 for center.
@@ -293,7 +312,7 @@ public class TableAppender extends Appen
         switch (horizontalBorder) {
             case -1: border = leftBorder;  break;
             case +1: border = rightBorder; break;
-            case  0: border = columnSeparator;   break;
+            case  0: border = columnSeparator; break;
             default: throw new AssertionError(horizontalBorder);
         }
         assert (verticalBorder >= -1) && (verticalBorder <= +1) : verticalBorder;
@@ -523,7 +542,9 @@ public class TableAppender extends Appen
     }
 
     /**
-     * Writes an horizontal separator.
+     * Writes an horizontal separator using the {@code '─'} character.
+     *
+     * @see #nextLine(char)
      */
     public void appendHorizontalSeparator() {
         if (currentColumn != 0 || buffer.length() != 0) {
@@ -595,6 +616,8 @@ public class TableAppender extends Appen
      *
      * @param  fill  character filling the rest of the line (default to whitespace).
      *              This character may be use as a row separator.
+     *
+     * @see #appendHorizontalSeparator()
      */
     public void nextLine(final char fill) {
         if (buffer.length() != 0) {

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/math/StatisticsFormat.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/math/StatisticsFormat.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/math/StatisticsFormat.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/math/StatisticsFormat.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -41,16 +41,32 @@ import static java.lang.Math.*;
 /**
  * Formats a {@link Statistics} object.
  * By default, newly created {@code StatisticsFormat} instances will format statistical values
- * in a tabular format using spaces as the column separator. This default configuration matches
- * the {@link Statistics#toString()} format.
+ * in a tabular format using spaces as the column separator.
  *
- * <div class="section">Limitations</div>
- * The current implementation can only format statistics - parsing is not yet implemented.
+ * <div class="note"><b>Example:</b>
+ * {@preformat text
+ *     Number of values:     8726
+ *     Minimum value:       6.853
+ *     Maximum value:       8.259
+ *     Mean value:          7.421
+ *     Root Mean Square:    7.846
+ *     Standard deviation:  6.489
+ * }
+ * </div>
+ *
+ * Like most {@link java.text.Format} implementations, this class is not thread-safe.
+ * Each thread should use its own {@code StatisticsFormat} instance or apply synchronization.
+ *
+ * <div class="warning"><b>Limitation:</b>
+ * the current implementation can only format statistics — parsing is not yet implemented.
+ * </div>
  *
  * @author  Martin Desruisseaux (MPO, IRD, Geomatys)
  * @since   0.3
  * @version 0.8
  * @module
+ *
+ * @see Statistics#toString()
  */
 public class StatisticsFormat extends TabularFormat<Statistics> {
     /**

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AbstractUnit.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AbstractUnit.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AbstractUnit.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AbstractUnit.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -27,6 +27,8 @@ import javax.measure.Quantity;
 import org.apache.sis.math.Fraction;
 import org.apache.sis.util.Characters;
 import org.apache.sis.util.ArgumentChecks;
+import org.apache.sis.util.ComparisonMode;
+import org.apache.sis.util.LenientComparable;
 import org.apache.sis.util.resources.Errors;
 
 
@@ -57,7 +59,7 @@ import org.apache.sis.util.resources.Err
  * @version 0.8
  * @module
  */
-abstract class AbstractUnit<Q extends Quantity<Q>> implements Unit<Q>, Serializable {
+abstract class AbstractUnit<Q extends Quantity<Q>> implements Unit<Q>, LenientComparable, Serializable {
     /**
      * For cross-version compatibility.
      */
@@ -270,16 +272,28 @@ abstract class AbstractUnit<Q extends Qu
     /**
      * Compares this unit with the given object for equality.
      *
-     * @param  other  the other object to compares with this unit, or {@code null}.
-     * @return {@code true} if the given object is equals to this unit.
+     * @param  other  the other object to compare with this unit, or {@code null}.
+     * @return {@code true} if the given object is equal to this unit.
      */
     @Override
-    public boolean equals(final Object other) {
-        if (other != null && other.getClass() == getClass()) {
-            final AbstractUnit<?> that = (AbstractUnit<?>) other;
-            return epsg == that.epsg && scope == that.scope && Objects.equals(symbol, that.symbol);
+    public final boolean equals(final Object other) {
+        return equals(other, ComparisonMode.STRICT);
+    }
+
+    /**
+     * Compares this unit with the given object for equality,
+     * optionally ignoring metadata and rounding errors.
+     */
+    @Override
+    public boolean equals(final Object other, final ComparisonMode mode) {
+        if (other == null || other.getClass() != getClass()) {
+            return false;
+        }
+        if (mode.isIgnoringMetadata()) {
+            return true;
         }
-        return false;
+        final AbstractUnit<?> that = (AbstractUnit<?>) other;
+        return epsg == that.epsg && scope == that.scope && Objects.equals(symbol, that.symbol);
     }
 
     /**

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AngleFormat.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AngleFormat.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AngleFormat.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/AngleFormat.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -16,6 +16,7 @@
  */
 package org.apache.sis.measure;
 
+import java.math.RoundingMode;
 import java.util.Objects;
 import java.util.Locale;
 import java.text.Format;
@@ -32,18 +33,17 @@ import org.apache.sis.util.ArgumentCheck
 import org.apache.sis.util.resources.Errors;
 import org.apache.sis.internal.util.LocalizedParseException;
 
-import static java.lang.Math.abs;
-import static java.lang.Math.rint;
 import static java.lang.Double.NaN;
 import static java.lang.Double.isNaN;
-import static java.lang.Double.isInfinite;
 import static org.apache.sis.math.MathFunctions.pow10;
 import static org.apache.sis.math.MathFunctions.truncate;
 import static org.apache.sis.math.MathFunctions.isNegative;
 import static org.apache.sis.math.DecimalFunctions.fractionDigitsForDelta;
 
+// Branch-dependent imports
 import org.apache.sis.internal.jdk8.JDK8;
 
+
 /**
  * Parses and formats angles according a specified pattern. The pattern is a string
  * containing any characters, with a special meaning for the following characters:
@@ -121,7 +121,7 @@ import org.apache.sis.internal.jdk8.JDK8
  *
  * @author  Martin Desruisseaux (MPO, IRD, Geomatys)
  * @since   0.3
- * @version 0.4
+ * @version 0.8
  * @module
  *
  * @see Angle
@@ -300,6 +300,13 @@ public class AngleFormat extends Format
                    secondsSuffix;
 
     /**
+     * The rounding mode, or {@code null} for the default mode (which is {@link RoundingMode#HALF_EVEN}).
+     *
+     * @see #RoundingMode()
+     */
+    private RoundingMode roundingMode;
+
+    /**
      * {@code true} if the {@link #parse(String, ParsePosition)} method is allowed to fallback
      * on the build-in default symbols if the string to parse doesn't match the pattern.
      *
@@ -723,6 +730,68 @@ public class AngleFormat extends Format
     }
 
     /**
+     * Returns the rounding mode. Default value is {@link RoundingMode#HALF_EVEN}.
+     *
+     * @return the rounding mode.
+     *
+     * @see NumberFormat#getRoundingMode()
+     *
+     * @since 0.8
+     */
+    public RoundingMode getRoundingMode() {
+        return (roundingMode != null) ? roundingMode : RoundingMode.HALF_EVEN;
+    }
+
+    /**
+     * Sets the rounding mode to the specified value. The given mode can be one of the following:
+     *
+     * <table class="sis">
+     *   <caption>Supported rounding modes</caption>
+     *   <tr><th>Rounding mode</th>                             <th>Result</th></tr>
+     *   <tr><td>{@link RoundingMode#UP        UP}</td>         <td>Round away from zero.</td></tr>
+     *   <tr><td>{@link RoundingMode#DOWN      DOWN}</td>       <td>Round towards zero.</td></tr>
+     *   <tr><td>{@link RoundingMode#CEILING   CEILING}</td>    <td>Round towards positive infinity.</td></tr>
+     *   <tr><td>{@link RoundingMode#FLOOR     FLOOR}</td>      <td>Round towards negative infinity.</td></tr>
+     *   <tr><td>{@link RoundingMode#HALF_EVEN HALF_EVEN}</td>  <td>Round towards nearest neighbor.</td></tr>
+     * </table>
+     *
+     * The {@link RoundingMode#HALF_UP} and {@link RoundingMode#HALF_DOWN HALF_DOWN} values are not supported
+     * by the current {@code AngleFormat} implementation.
+     *
+     * @param  mode  the new rounding mode.
+     *
+     * @see NumberFormat#setRoundingMode(RoundingMode)
+     *
+     * @since 0.8
+     */
+    public void setRoundingMode(final RoundingMode mode) {
+        ArgumentChecks.ensureNonNull("mode", mode);
+        if (mode == RoundingMode.HALF_UP || mode == RoundingMode.HALF_DOWN) {
+            throw new IllegalArgumentException(Errors.format(Errors.Keys.UnsupportedArgumentValue_1, mode));
+        }
+        roundingMode = mode;
+    }
+
+    /**
+     * Rounds the given value according current {@link #roundingMode}.
+     *
+     * @param  sign   the sign of the value to round.
+     * @param  value  the positive value to round.
+     * @return the rounded positive value.
+     */
+    private double round(final double sign, final double value) {
+        if (roundingMode != null) {
+            switch (roundingMode) {
+                case UP:      return Math.ceil (value);
+                case DOWN:    return Math.floor(value);
+                case CEILING: return Math.abs(Math.ceil (Math.copySign(value, sign)));
+                case FLOOR:   return Math.abs(Math.floor(Math.copySign(value, sign)));
+            }
+        }
+        return Math.rint(value);
+    }
+
+    /**
      * Returns the minimum number of digits allowed in the fraction portion of the last field.
      * This value can be set by the repetition of {@code 'd'}, {@code 'm'} or {@code 's'} symbol
      * in the pattern.
@@ -901,7 +970,7 @@ public class AngleFormat extends Format
     public StringBuffer format(final double angle, StringBuffer toAppendTo, final FieldPosition pos) {
         final int offset = toAppendTo.length();
         final int fieldPos = getField(pos);
-        if (isNaN(angle) || isInfinite(angle)) {
+        if (!JDK8.isFinite(angle)) {
             toAppendTo = numberFormat().format(angle, toAppendTo, dummyFieldPosition());
             if (fieldPos >= DEGREES_FIELD && fieldPos <= SECONDS_FIELD) {
                 pos.setBeginIndex(offset);
@@ -917,8 +986,11 @@ public class AngleFormat extends Format
         double minutes = NaN;
         double seconds = NaN;
         int maximumFractionDigits = fractionFieldWidth;
-        if (minutesFieldWidth != 0 && !isNaN(angle)) {
-            minutes = abs(degrees - (degrees = truncate(degrees))) * 60;
+        if (minutesFieldWidth == 0) {
+            final double p = pow10(maximumFractionDigits);
+            degrees = round(angle, degrees * p) / p;
+        } else {
+            minutes = Math.abs(degrees - (degrees = truncate(degrees))) * 60;
             /*
              * Limit the maximal number of fraction digits to the amount of significant digits for a 'double' value.
              * The intend is to avoid non-significant garbage that are pure artifacts from the conversion from base
@@ -930,13 +1002,13 @@ public class AngleFormat extends Format
             final double p = pow10(maximumFractionDigits);
             if (secondsFieldWidth != 0) {
                 seconds = (minutes - (minutes = truncate(minutes))) * 60;
-                seconds = rint(seconds * p) / p;                            // Correction for rounding errors.
+                seconds = round(angle, seconds * p) / p;                     // Correction for rounding errors.
                 if (seconds >= 60) {                    // We do not expect > 60 (only == 60), but let be safe.
                     seconds = 0;
                     minutes++;
                 }
             } else {
-                minutes = rint(minutes * p) / p;        // Correction for rounding errors.
+                minutes = round(angle, minutes * p) / p;                     // Correction for rounding errors.
             }
             if (minutes >= 60) {                        // We do not expect > 60 (only == 60), but let be safe.
                 minutes = 0;
@@ -1117,7 +1189,7 @@ public class AngleFormat extends Format
     {
         try {
             showLeadingFields = true;
-            toAppendTo = format(abs(angle), toAppendTo, pos);
+            toAppendTo = format(Math.abs(angle), toAppendTo, pos);
         } finally {
             showLeadingFields = false;
         }
@@ -1760,8 +1832,8 @@ BigBoss:    switch (skipSuffix(source, p
     @Override
     public int hashCode() {
         return Objects.hash(degreesFieldWidth, minutesFieldWidth, secondsFieldWidth, fractionFieldWidth,
-                minimumFractionDigits, useDecimalSeparator, isFallbackAllowed, optionalFields, locale,
-                prefix, degreesSuffix, minutesSuffix, secondsSuffix) ^ (int) serialVersionUID;
+                minimumFractionDigits, useDecimalSeparator, isFallbackAllowed, optionalFields, roundingMode,
+                locale, prefix, degreesSuffix, minutesSuffix, secondsSuffix) ^ (int) serialVersionUID;
     }
 
     /**
@@ -1784,6 +1856,7 @@ BigBoss:    switch (skipSuffix(source, p
                    useDecimalSeparator   == cast.useDecimalSeparator   &&
                    isFallbackAllowed     == cast.isFallbackAllowed     &&
                    optionalFields        == cast.optionalFields        &&
+                   roundingMode          == cast.roundingMode          &&
                    Objects.equals(locale,        cast.locale)          &&
                    Objects.equals(prefix,        cast.prefix)          &&
                    Objects.equals(degreesSuffix, cast.degreesSuffix)   &&

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConcatenatedConverter.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConcatenatedConverter.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConcatenatedConverter.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConcatenatedConverter.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -20,6 +20,9 @@ import java.util.List;
 import java.util.ArrayList;
 import javax.measure.UnitConverter;
 import org.apache.sis.util.ArgumentChecks;
+import org.apache.sis.util.ComparisonMode;
+import org.apache.sis.util.LenientComparable;
+import org.apache.sis.util.Utilities;
 
 
 /**
@@ -30,7 +33,7 @@ import org.apache.sis.util.ArgumentCheck
  * @version 0.8
  * @module
  */
-final class ConcatenatedConverter extends AbstractConverter {
+final class ConcatenatedConverter extends AbstractConverter implements LenientComparable {
     /**
      * For cross-version compatibility.
      */
@@ -161,4 +164,17 @@ final class ConcatenatedConverter extend
         }
         return false;
     }
+
+    /**
+     * Compares this converter with the given object for equality, optionally ignoring rounding errors.
+     */
+    @Override
+    public boolean equals(final Object other, final ComparisonMode mode) {
+        if (other instanceof ConcatenatedConverter) {
+            final ConcatenatedConverter o = (ConcatenatedConverter) other;
+            return Utilities.deepEquals(c1, o.c1, mode) &&
+                   Utilities.deepEquals(c2, o.c2, mode);
+        }
+        return false;
+    }
 }

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConventionalUnit.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConventionalUnit.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConventionalUnit.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/ConventionalUnit.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -26,6 +26,8 @@ import javax.measure.IncommensurableExce
 import org.apache.sis.util.resources.Errors;
 import org.apache.sis.util.ArgumentChecks;
 import org.apache.sis.util.Characters;
+import org.apache.sis.util.ComparisonMode;
+import org.apache.sis.util.Utilities;
 import org.apache.sis.math.Fraction;
 import org.apache.sis.math.MathFunctions;
 import org.apache.sis.internal.util.Numerics;
@@ -439,19 +441,21 @@ final class ConventionalUnit<Q extends Q
     }
 
     /**
-     * Compares this unit with the given object for equality.
+     * Compares this unit with the given object for equality,
+     * optionally ignoring metadata and rounding errors.
      *
-     * @param  other  the other object to compares with this unit, or {@code null}.
-     * @return {@code true} if the given object is equals to this unit.
+     * @param  other  the other object to compare with this unit, or {@code null}.
+     * @return {@code true} if the given object is equal to this unit.
      */
     @Override
-    public boolean equals(final Object other) {
+    public boolean equals(final Object other, final ComparisonMode mode) {
         if (other == this) {
             return true;
         }
-        if (super.equals(other)) {
+        if (super.equals(other, mode)) {
             final ConventionalUnit<?> that = (ConventionalUnit<?>) other;
-            return target.equals(that.target) && toTarget.equals(that.toTarget);
+            return Utilities.deepEquals(target,   that.target,   mode) &&
+                   Utilities.deepEquals(toTarget, that.toTarget, mode);
         }
         return false;
     }

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/LinearConverter.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/LinearConverter.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/LinearConverter.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/LinearConverter.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -25,6 +25,8 @@ import javax.measure.UnitConverter;
 import org.apache.sis.util.Debug;
 import org.apache.sis.util.ArgumentChecks;
 import org.apache.sis.util.StringBuilders;
+import org.apache.sis.util.ComparisonMode;
+import org.apache.sis.util.LenientComparable;
 import org.apache.sis.math.DecimalFunctions;
 import org.apache.sis.math.MathFunctions;
 import org.apache.sis.math.Fraction;
@@ -49,7 +51,7 @@ import org.apache.sis.internal.util.Nume
  * @version 0.8
  * @module
  */
-final class LinearConverter extends AbstractConverter {
+final class LinearConverter extends AbstractConverter implements LenientComparable {
     /**
      * For cross-version compatibility.
      */
@@ -450,6 +452,18 @@ final class LinearConverter extends Abst
     }
 
     /**
+     * Compares this converter with the given object for equality, optionally ignoring rounding errors.
+     */
+    @Override
+    public boolean equals(final Object other, final ComparisonMode mode) {
+        if (mode.isApproximative()) {
+            return (other instanceof LinearConverter) && equivalent((LinearConverter) other);
+        } else {
+            return equals(other);
+        }
+    }
+
+    /**
      * Returns {@code true} if the given converter perform the same conversion than this converter,
      * except for rounding errors.
      */

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/SystemUnit.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/SystemUnit.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/SystemUnit.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/measure/SystemUnit.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -28,6 +28,7 @@ import javax.measure.UnconvertibleExcept
 import javax.measure.IncommensurableException;
 import org.apache.sis.util.ArgumentChecks;
 import org.apache.sis.util.ObjectConverters;
+import org.apache.sis.util.ComparisonMode;
 import org.apache.sis.util.resources.Errors;
 import org.apache.sis.internal.converter.SurjectiveConverter;
 import org.apache.sis.math.Fraction;
@@ -482,17 +483,18 @@ final class SystemUnit<Q extends Quantit
     }
 
     /**
-     * Compares this unit with the given object for equality.
+     * Compares this unit with the given object for equality,
+     * optionally ignoring metadata and rounding errors.
      *
-     * @param  other  the other object to compares with this unit, or {@code null}.
-     * @return {@code true} if the given object is equals to this unit.
+     * @param  other  the other object to compare with this unit, or {@code null}.
+     * @return {@code true} if the given object is equal to this unit.
      */
     @Override
-    public boolean equals(final Object other) {
+    public boolean equals(final Object other, final ComparisonMode mode) {
         if (other == this) {
             return true;
         }
-        if (super.equals(other)) {
+        if (super.equals(other, mode)) {
             final SystemUnit<?> that = (SystemUnit<?>) other;
             return Objects.equals(quantity, that.quantity) && dimension.equals(that.dimension);
         }

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/StringBuilders.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/StringBuilders.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/StringBuilders.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/StringBuilders.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -161,6 +161,72 @@ public final class StringBuilders extend
     }
 
     /**
+     * Inserts the given character <var>n</var> time at the given position.
+     * This method does nothing if the given {@code count} is zero.
+     *
+     * @param  buffer  the buffer where to insert the character.
+     * @param  offset  position where to insert the characters.
+     * @param  c       the character to repeat.
+     * @param  count   number of time to repeat the given character.
+     * @throws NullPointerException if the given buffer is null.
+     * @throws IndexOutOfBoundsException if the given index is invalid.
+     * @throws IllegalArgumentException if the given count is negative.
+     *
+     * @since 0.8
+     */
+    public static void repeat(final StringBuilder buffer, final int offset, final char c, final int count) {
+        ArgumentChecks.ensureNonNull("buffer", buffer);
+        switch (count) {
+            case 0:  break;
+            case 1:  buffer.insert(offset, c); break;
+            default: {
+                ArgumentChecks.ensurePositive("count", count);
+                final CharSequence r;
+                switch (c) {
+                    case ' ': r = CharSequences.spaces(count); break;
+                    case '0': r = Repeat.ZERO; break;
+                    default:  r = new Repeat(c, count); break;
+                }
+                buffer.insert(offset, r, 0, count);
+                break;
+            }
+        }
+    }
+
+    /**
+     * A sequence of a constant character. This implementation does not perform any argument
+     * check since it is for {@link StringBuilder#append(CharSequence, int, int)} usage only.
+     * The intend is to allow {@code StringBuilder} to append the characters in one operation
+     * instead than looping on {@link StringBuilder#insert(int, char)} (which would require
+     * memory move on each call).
+     */
+    private static final class Repeat implements CharSequence {
+        /** An infinite sequence of {@code '0'} character. */
+        static final Repeat ZERO = new Repeat('0', Integer.MAX_VALUE);
+
+        /** The character to repeat. */
+        private final char c;
+
+        /** Number of times the character is repeated. */
+        private final int n;
+
+        /** Creates a new sequence of constant character. */
+        Repeat(final char c, final int n) {
+            this.c = c;
+            this.n = n;
+        }
+
+        /** Returns the number of times the character is repeated. */
+        @Override public int length() {return n;}
+
+        /** Returns the constant character, regardless the index. */
+        @Override public char charAt(int i) {return c;}
+
+        /** Returns a sequence of the same constant character but different length. */
+        @Override public CharSequence subSequence(int start, int end) {return new Repeat(c, end - start);}
+    }
+
+    /**
      * Trims the fractional part of the given formatted number, provided that it doesn't change
      * the value. This method assumes that the number is formatted in the US locale, typically
      * by the {@link Double#toString(double)} method.
@@ -183,11 +249,9 @@ public final class StringBuilders extend
     public static void trimFractionalPart(final StringBuilder buffer) {
         ArgumentChecks.ensureNonNull ("buffer", buffer);
         for (int i=buffer.length(); i > 0;) {
-            final int c = buffer.codePointBefore(i);
-            i -= charCount(c);
-            switch (c) {
+            switch (buffer.charAt(--i)) {               // No need to use Unicode code points here.
                 case '0': continue;
-                case '.': buffer.setLength(i); // Fall through
+                case '.': buffer.setLength(i);          // Fall through
                 default : return;
             }
         }

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -106,6 +106,11 @@ public final class Errors extends Indexe
         public static final short CanNotConvertValue_2 = 8;
 
         /**
+         * Can not copy “{0}”.
+         */
+        public static final short CanNotCopy_1 = 169;
+
+        /**
          * Can not open “{0}”.
          */
         public static final short CanNotOpen_1 = 9;
@@ -865,6 +870,16 @@ public final class Errors extends Indexe
         public static final short UnspecifiedFormatForClass_1 = 158;
 
         /**
+         * The “{0}” argument value is unsupported.
+         */
+        public static final short UnsupportedArgumentValue_1 = 170;
+
+        /**
+         * The “{0}” datum is not supported by this operation.
+         */
+        public static final short UnsupportedDatum_1 = 168;
+
+        /**
          * Version {1} of {0} format is not supported.
          */
         public static final short UnsupportedFormatVersion_2 = 159;
@@ -886,7 +901,7 @@ public final class Errors extends Indexe
         public static final short UnsupportedOperation_1 = 162;
 
         /**
-         * The ‘{0}’ type is unsupported.
+         * The ‘{0}’ type is not supported in this context.
          */
         public static final short UnsupportedType_1 = 163;
 

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.properties
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.properties?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.properties [ISO-8859-1] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors.properties [ISO-8859-1] Tue Mar  7 23:37:49 2017
@@ -32,6 +32,7 @@ CanNotConnectTo_1                 = Can
 CanNotConvertFromType_2           = Can not convert from type \u2018{0}\u2019 to type \u2018{1}\u2019.
 CanNotConvertValue_2              = Can not convert value \u201c{0}\u201d to type \u2018{1}\u2019.
 CanNotCompute_1                   = Can not compute \u201c{0}\u201d.
+CanNotCopy_1                      = Can not copy \u201c{0}\u201d.
 CanNotOpen_1                      = Can not open \u201c{0}\u201d.
 CanNotParseFile_2                 = Can not parse \u201c{1}\u201d as a file in the {0} format.
 CanNotRead_1                      = Can not read \u201c{0}\u201d.
@@ -188,7 +189,9 @@ UnsupportedFormatVersion_2        = Vers
 UnsupportedImplementation_1       = Can not handle this instance of \u2018{0}\u2019 because arbitrary implementations are not yet supported.
 UnsupportedInterpolation_1        = The \u201c{0}\u201d interpolation is unsupported.
 UnsupportedOperation_1            = The \u2018{0}\u2019 operation is unsupported.
-UnsupportedType_1                 = The \u2018{0}\u2019 type is unsupported.
+UnsupportedArgumentValue_1        = The \u201c{0}\u201d argument value is unsupported.
+UnsupportedDatum_1                = The \u201c{0}\u201d datum is not supported by this operation.
+UnsupportedType_1                 = The \u2018{0}\u2019 type is not supported in this context.
 ValueAlreadyDefined_1             = A value is already defined for \u201c{0}\u201d.
 ValueNotGreaterThanZero_2         = Value \u2018{0}\u2019 = {1} is invalid. Expected a number greater than 0.
 ValueOutOfRange_4                 = Value \u2018{0}\u2019 = {3} is invalid. Expected a value in the [{1} \u2026 {2}] range.

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors_fr.properties
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors_fr.properties?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors_fr.properties [ISO-8859-1] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Errors_fr.properties [ISO-8859-1] Tue Mar  7 23:37:49 2017
@@ -29,6 +29,7 @@ CanNotConnectTo_1                 = Ne p
 CanNotConvertFromType_2           = Ne peut pas convertir du type \u2018{0}\u2019 vers le type \u2018{1}\u2019.
 CanNotConvertValue_2              = La valeur \u00ab\u202f{0}\u202f\u00bb ne peut pas \u00eatre convertie vers le type \u2018{1}\u2019.
 CanNotCompute_1                   = Ne peut pas calculer \u00ab\u202f{0}\u202f\u00bb.
+CanNotCopy_1                      = Ne peut pas copier \u00ab\u202f{0}\u202f\u00bb.
 CanNotOpen_1                      = Ne peut pas ouvrir \u00ab\u202f{0}\u202f\u00bb.
 CanNotParseFile_2                 = Ne peut pas lire \u00ab\u202f{1}\u202f\u00bb comme un fichier au format {0}.
 CanNotRead_1                      = Ne peut pas lire \u00ab\u202f{0}\u202f\u00bb.
@@ -184,7 +185,9 @@ UnsupportedFormatVersion_2        = La v
 UnsupportedImplementation_1       = Cette instance de \u2018{0}\u2019 ne peut pas \u00eatre g\u00e9r\u00e9e parce que les impl\u00e9mentations arbitraires ne sont pas encore support\u00e9es.
 UnsupportedInterpolation_1        = L\u2019interpolation \u201c{0}\u201d n\u2019est pas support\u00e9e.
 UnsupportedOperation_1            = L\u2019op\u00e9ration \u2018{0}\u2019 n\u2019est pas support\u00e9e.
-UnsupportedType_1                 = Le type \u2018{0}\u2019 n\u2019est pas support\u00e9.
+UnsupportedArgumentValue_1        = La valeur d\u2019argument \u00ab\u202f{0}\u202f\u00bb n\u2019est pas support\u00e9e.
+UnsupportedDatum_1                = Le r\u00e9f\u00e9rentiel \u00ab\u202f{0}\u202f\u00bb n\u2019est pas support\u00e9 par cette op\u00e9ration.
+UnsupportedType_1                 = Le type \u2018{0}\u2019 n\u2019est pas support\u00e9 dans ce contexte.
 ValueAlreadyDefined_1             = Une valeur est d\u00e9j\u00e0 d\u00e9finie pour \u00ab\u202f{0}\u202f\u00bb.
 ValueNotGreaterThanZero_2         = La valeur \u2018{0}\u2019 = {1} n\u2019est pas valide. On attendait un nombre positif non-nul.
 ValueOutOfRange_4                 = La valeur \u2018{0}\u2019 = {3} est invalide. Une valeur dans la plage [{1} \u2026 {2}] \u00e9tait attendue.

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/IndexedResourceBundle.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/IndexedResourceBundle.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/IndexedResourceBundle.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/IndexedResourceBundle.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -451,6 +451,25 @@ public class IndexedResourceBundle exten
     }
 
     /**
+     * Writes the localized string identified by the given key followed by a colon.
+     * The way to write the colon depends on the language.
+     *
+     * @param  key         the key for the desired string.
+     * @param  toAppendTo  where to write the localized string followed by a colon.
+     * @throws IOException if an error occurred while writing to the given destination.
+     *
+     * @since 0.8
+     */
+    public final void appendLabel(final short key, final Appendable toAppendTo) throws IOException {
+        toAppendTo.append(getString(key));
+        if (Locale.FRENCH.getLanguage().equals(getLocale().getLanguage())) {
+            toAppendTo.append("\u00A0:");
+        } else {
+            toAppendTo.append(':');
+        }
+    }
+
+    /**
      * Gets a string for the given key and appends "…" to it.
      * This method is typically used for creating menu items.
      *
@@ -470,7 +489,10 @@ public class IndexedResourceBundle exten
      * @param  key  the key for the desired string.
      * @return the string for the given key.
      * @throws MissingResourceException if no object for the given key can be found.
+     *
+     * @deprecated Replaced by {@link #appendLabel(short, Appendable)}.
      */
+    @Deprecated
     public final String getLabel(final short key) throws MissingResourceException {
         String label = getString(key);
         if (Locale.FRENCH.getLanguage().equals(getLocale().getLanguage())) {

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -62,11 +62,21 @@ public final class Vocabulary extends In
         public static final short Accuracy = 1;
 
         /**
+         * Administrator
+         */
+        public static final short Administrator = 130;
+
+        /**
          * Aliases
          */
         public static final short Aliases = 2;
 
         /**
+         * Alternative identifiers
+         */
+        public static final short AlternativeIdentifiers = 131;
+
+        /**
          * Angle
          */
         public static final short Angle = 3;
@@ -127,6 +137,11 @@ public final class Vocabulary extends In
         public static final short Classpath = 14;
 
         /**
+         * Code
+         */
+        public static final short Code = 128;
+
+        /**
          * {0} code
          */
         public static final short Code_1 = 15;
@@ -147,6 +162,16 @@ public final class Vocabulary extends In
         public static final short Container = 18;
 
         /**
+         * Coordinate
+         */
+        public static final short Coordinate = 129;
+
+        /**
+         * Coordinate reference system
+         */
+        public static final short CoordinateRefSys = 132;
+
+        /**
          * Correlation
          */
         public static final short Correlation = 19;
@@ -252,6 +277,11 @@ public final class Vocabulary extends In
         public static final short DublinJulian = 38;
 
         /**
+         * East bound
+         */
+        public static final short EastBound = 133;
+
+        /**
          * Ellipsoid
          */
         public static final short Ellipsoid = 39;
@@ -267,6 +297,11 @@ public final class Vocabulary extends In
         public static final short EllipsoidalHeight = 41;
 
         /**
+         * End date
+         */
+        public static final short EndDate = 134;
+
+        /**
          * {0} entr{0,choice,0#y|2#ies}
          */
         public static final short EntryCount_1 = 121;
@@ -292,6 +327,11 @@ public final class Vocabulary extends In
         public static final short GeodeticDataset = 45;
 
         /**
+         * Geographic identifier
+         */
+        public static final short GeographicIdentifier = 135;
+
+        /**
          * Height
          */
         public static final short Height = 46;
@@ -382,6 +422,11 @@ public final class Vocabulary extends In
         public static final short Localization = 63;
 
         /**
+         * Location type
+         */
+        public static final short LocationType = 136;
+
+        /**
          * Logging
          */
         public static final short Logging = 64;
@@ -397,6 +442,11 @@ public final class Vocabulary extends In
         public static final short Mandatory = 66;
 
         /**
+         * Mapping
+         */
+        public static final short Mapping = 127;
+
+        /**
          * Maximum value
          */
         public static final short MaximumValue = 67;
@@ -432,6 +482,11 @@ public final class Vocabulary extends In
         public static final short None = 73;
 
         /**
+         * North bound
+         */
+        public static final short NorthBound = 137;
+
+        /**
          * Note
          */
         public static final short Note = 74;
@@ -527,6 +582,11 @@ public final class Vocabulary extends In
         public static final short RemoteConfiguration = 89;
 
         /**
+         * Representative value
+         */
+        public static final short RepresentativeValue = 141;
+
+        /**
          * Root
          */
         public static final short Root = 90;
@@ -552,11 +612,21 @@ public final class Vocabulary extends In
         public static final short Source = 93;
 
         /**
+         * South bound
+         */
+        public static final short SouthBound = 138;
+
+        /**
          * Standard deviation
          */
         public static final short StandardDeviation = 94;
 
         /**
+         * Start date
+         */
+        public static final short StartDate = 139;
+
+        /**
          * Subset of {0}
          */
         public static final short SubsetOf_1 = 95;
@@ -677,6 +747,11 @@ public final class Vocabulary extends In
         public static final short Warnings = 117;
 
         /**
+         * West bound
+         */
+        public static final short WestBound = 140;
+
+        /**
          * World
          */
         public static final short World = 118;

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.properties
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.properties?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.properties [ISO-8859-1] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary.properties [ISO-8859-1] Tue Mar  7 23:37:49 2017
@@ -15,7 +15,9 @@
 # limitations under the License.
 #
 Accuracy                = Accuracy
+Administrator           = Administrator
 Aliases                 = Aliases
+AlternativeIdentifiers  = Alternative identifiers
 Angle                   = Angle
 AngularDegrees          = Degrees
 AngularMinutes          = Minutes
@@ -28,10 +30,13 @@ CausedBy_1              = Caused by {0}
 CharacterEncoding       = Character encoding
 Characteristics         = Characteristics
 Classpath               = Classpath
+Code                    = Code
 Code_1                  = {0} code
 Commands                = Commands
 ConstantPressureSurface = Constant pressure surface
 Container               = Container
+Coordinate              = Coordinate
+CoordinateRefSys        = Coordinate reference system
 Correlation             = Correlation
 CurrentDateTime         = Current date and time
 CurrentDirectory        = Current directory
@@ -53,14 +58,17 @@ Directory               = Directory
 DittoMark               = \u2033
 Domain                  = Domain
 DublinJulian            = Dublin Julian
+EastBound               = East bound
 Ellipsoid               = Ellipsoid
 EllipsoidChange         = Ellipsoid change
 EllipsoidalHeight       = Ellipsoidal height
+EndDate                 = End date
 EntryCount_1            = {0} entr{0,choice,0#y|2#ies}
 Geocentric              = Geocentric
 GeocentricRadius        = Geocentric radius
 GeocentricConversion    = Geocentric conversion
 GeodeticDataset         = Geodetic dataset
+GeographicIdentifier    = Geographic identifier
 Height                  = Height
 Identifier              = Identifier
 Implementation          = Implementation
@@ -80,8 +88,10 @@ Libraries               = Libraries
 LocalConfiguration      = Local configuration
 Locale                  = Locale
 Localization            = Localization
+LocationType            = Location type
 Logging                 = Logging
 Mandatory               = Mandatory
+Mapping                 = Mapping
 MaximumValue            = Maximum value
 MeanValue               = Mean value
 MinimumValue            = Minimum value
@@ -90,6 +100,7 @@ ModifiedJulian          = Modified Julia
 Name                    = Name
 None                    = None
 Note                    = Note
+NorthBound              = North bound
 NumberOfValues          = Number of values
 NumberOfNaN             = Number of \u2018NaN\u2019
 Obligation              = Obligation
@@ -108,12 +119,15 @@ Quoted_1                = \u201c{0}\u201
 Read                    = Read
 Remarks                 = Remarks
 RemoteConfiguration     = Remote configuration
+RepresentativeValue     = Representative value
 Root                    = Root
 RootMeanSquare          = Root Mean Square
 Scale                   = Scale
 SlashSeparatedList_2    = {0}/{1}
 Source                  = Source
+SouthBound              = South bound
 StandardDeviation       = Standard deviation
+StartDate               = Start date
 SubsetOf_1              = Subset of {0}
 SupersededBy_1          = Superseded by {0}.
 TemporaryFiles          = Temporary files
@@ -138,5 +152,6 @@ Version_2               = {0} version {1
 Versions                = Versions
 Vertical                = Vertical
 Warnings                = Warnings
+WestBound               = West bound
 World                   = World
 Write                   = Write

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary_fr.properties
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary_fr.properties?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary_fr.properties [ISO-8859-1] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/util/resources/Vocabulary_fr.properties [ISO-8859-1] Tue Mar  7 23:37:49 2017
@@ -22,7 +22,9 @@
 #   U+00A0 NO-BREAK SPACE         before  :
 #
 Accuracy                = Pr\u00e9cision
+Administrator           = Administrateur
 Aliases                 = Alias
+AlternativeIdentifiers  = Identifiants alternatifs
 Angle                   = Angle
 AngularDegrees          = Degr\u00e9s
 AngularMinutes          = Minutes
@@ -35,10 +37,13 @@ CausedBy_1              = Caus\u00e9e pa
 CharacterEncoding       = Encodage des caract\u00e8res
 Characteristics         = Caract\u00e9ristiques
 Classpath               = Chemin de classes
+Code                    = Code
 Code_1                  = Code {0}
 Commands                = Commandes
 ConstantPressureSurface = Surface \u00e0 pression constante
 Container               = Conteneur
+Coordinate              = Coordonn\u00e9e
+CoordinateRefSys        = Syst\u00e8me de r\u00e9f\u00e9rence des coordonn\u00e9es
 Correlation             = Corr\u00e9lation
 CurrentDateTime         = Date et heure courantes
 CurrentDirectory        = R\u00e9pertoire courant
@@ -60,14 +65,17 @@ Directory               = R\u00e9pertoir
 DittoMark               = \u2033
 Domain                  = Domaine
 DublinJulian            = Julien Dublin
+EastBound               = Limite est
 Ellipsoid               = Ellipso\u00efde
 EllipsoidChange         = Changement d\u2019ellipso\u00efde
 EllipsoidalHeight       = Hauteur ellipso\u00efdale
 EntryCount_1            = {0} entr\u00e9e{0,choice,0#|2#s}
+EndDate                 = Date de fin
 Geocentric              = G\u00e9ocentrique
 GeocentricRadius        = Rayon g\u00e9ocentrique
 GeocentricConversion    = Conversion g\u00e9ocentrique
 GeodeticDataset         = Base de donn\u00e9es g\u00e9od\u00e9sique
+GeographicIdentifier    = Identifiant g\u00e9ographique
 Height                  = Hauteur
 Identifier              = Identifiant
 Implementation          = Impl\u00e9mentation
@@ -87,8 +95,10 @@ Libraries               = Biblioth\u00e8
 LocalConfiguration      = Configuration locale
 Locale                  = Locale
 Localization            = R\u00e9gionalisation
+LocationType            = Type de location
 Logging                 = Journalisation
 Mandatory               = Requis
+Mapping                 = Cartographie
 MaximumValue            = Valeur maximale
 MeanValue               = Valeur moyenne
 MinimumValue            = Valeur minimale
@@ -97,6 +107,7 @@ ModifiedJulian          = Julien modifi\
 Name                    = Nom
 None                    = Aucun
 Note                    = Note
+NorthBound              = Limite nord
 NumberOfValues          = Nombre de valeurs
 NumberOfNaN             = Nombre de \u2018NaN\u2019
 Obligation              = Obligation
@@ -115,12 +126,15 @@ Quoted_1                = \u00ab\u202f{0
 Read                    = Lecture
 Remarks                 = Remarques
 RemoteConfiguration     = Configuration distante
+RepresentativeValue     = Valeur repr\u00e9sentative
 Root                    = Racine
 RootMeanSquare          = Moyenne quadratique
 Scale                   = \u00c9chelle
 SlashSeparatedList_2    = {0}/{1}
 Source                  = Source
+SouthBound              = Limite sud
 StandardDeviation       = \u00c9cart type
+StartDate               = Date de d\u00e9part
 SubsetOf_1              = Sous-ensemble de {0}
 SupersededBy_1          = Remplac\u00e9 par {0}.
 TemporaryFiles          = Fichiers temporaires
@@ -145,5 +159,6 @@ Version_2               = {0} version {1
 Versions                = Versions
 Vertical                = Vertical
 Warnings                = Avertissements
+WestBound               = Limite ouest
 World                   = Monde
 Write                   = \u00c9criture

Modified: sis/trunk/core/sis-utility/src/main/java/org/apache/sis/xml/XML.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/main/java/org/apache/sis/xml/XML.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/main/java/org/apache/sis/xml/XML.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/main/java/org/apache/sis/xml/XML.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -37,7 +37,9 @@ import javax.xml.bind.JAXBException;
 import javax.xml.transform.Source;
 import javax.xml.transform.Result;
 import javax.xml.transform.stax.StAXSource;
+import javax.xml.transform.stax.StAXResult;
 import javax.xml.stream.XMLStreamReader;
+import javax.xml.stream.XMLStreamWriter;
 import org.apache.sis.util.Static;
 import org.apache.sis.util.Version;
 import org.apache.sis.util.Workaround;
@@ -453,7 +455,21 @@ public final class XML extends Static {
                 marshaller.setProperty(entry.getKey(), entry.getValue());
             }
         }
-        marshaller.marshal(object, output);
+        /*
+         * STAX results are not handled by JAXB as of JDK 8. We have to handle those cases ourselves.
+         * This workaround should be removed if a future JDK version handles those cases.
+         */
+        if (output instanceof StAXResult) {
+            @Workaround(library = "JDK", version = "1.8")
+            final XMLStreamWriter writer = ((StAXResult) output).getXMLStreamWriter();
+            if (writer != null) {
+                marshaller.marshal(object, writer);
+            } else {
+                marshaller.marshal(object, ((StAXResult) output).getXMLEventWriter());
+            }
+        } else {
+            marshaller.marshal(object, output);
+        }
         pool.recycle(marshaller);
     }
 

Modified: sis/trunk/core/sis-utility/src/test/java/org/apache/sis/measure/AngleFormatTest.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/test/java/org/apache/sis/measure/AngleFormatTest.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/test/java/org/apache/sis/measure/AngleFormatTest.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/test/java/org/apache/sis/measure/AngleFormatTest.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -17,6 +17,7 @@
 package org.apache.sis.measure;
 
 import java.util.Locale;
+import java.math.RoundingMode;
 import java.text.FieldPosition;
 import java.text.AttributedCharacterIterator;
 import java.text.ParseException;
@@ -34,7 +35,7 @@ import static org.apache.sis.test.TestUt
  *
  * @author  Martin Desruisseaux (MPO, IRD, Geomatys)
  * @since   0.3
- * @version 0.4
+ * @version 0.8
  * @module
  */
 @DependsOn({
@@ -223,6 +224,30 @@ public final strictfp class AngleFormatT
     }
 
     /**
+     * Tests formatting the same value with different rounding modes.
+     *
+     * @since 0.8
+     */
+    @Test
+    @DependsOnMethod("testDegreeMinutesSeconds")
+    public void testRoundingMode() {
+        final AngleFormat f = new AngleFormat("DD°MM′SS″", Locale.CANADA);
+        Angle angle = new Angle(12.515625);
+        f.setRoundingMode(RoundingMode.DOWN);      assertEquals("12°30′56″", f.format(angle));
+        f.setRoundingMode(RoundingMode.UP);        assertEquals("12°30′57″", f.format(angle));
+        f.setRoundingMode(RoundingMode.FLOOR);     assertEquals("12°30′56″", f.format(angle));
+        f.setRoundingMode(RoundingMode.CEILING);   assertEquals("12°30′57″", f.format(angle));
+        f.setRoundingMode(RoundingMode.HALF_EVEN); assertEquals("12°30′56″", f.format(angle));
+
+        angle = new Angle(-12.515625);
+        f.setRoundingMode(RoundingMode.DOWN);      assertEquals("-12°30′56″", f.format(angle));
+        f.setRoundingMode(RoundingMode.UP);        assertEquals("-12°30′57″", f.format(angle));
+        f.setRoundingMode(RoundingMode.FLOOR);     assertEquals("-12°30′57″", f.format(angle));
+        f.setRoundingMode(RoundingMode.CEILING);   assertEquals("-12°30′56″", f.format(angle));
+        f.setRoundingMode(RoundingMode.HALF_EVEN); assertEquals("-12°30′56″", f.format(angle));
+    }
+
+    /**
      * Tests with optional digits.
      */
     @Test

Modified: sis/trunk/core/sis-utility/src/test/java/org/apache/sis/util/StringBuildersTest.java
URL: http://svn.apache.org/viewvc/sis/trunk/core/sis-utility/src/test/java/org/apache/sis/util/StringBuildersTest.java?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/core/sis-utility/src/test/java/org/apache/sis/util/StringBuildersTest.java [UTF-8] (original)
+++ sis/trunk/core/sis-utility/src/test/java/org/apache/sis/util/StringBuildersTest.java [UTF-8] Tue Mar  7 23:37:49 2017
@@ -80,6 +80,26 @@ public final strictfp class StringBuilde
     }
 
     /**
+     * Tests the {@link StringBuilders#repeat(StringBuilder, int, char, int)} method.
+     *
+     * @since 0.8
+     */
+    @Test
+    public void testRepeat() {
+        final StringBuilder buffer = new StringBuilder("AB12");
+        repeat(buffer, 2, 'C', 0);
+        assertEquals("AB12", buffer.toString());
+        repeat(buffer, 2, 'C', 1);
+        assertEquals("ABC12", buffer.toString());
+        repeat(buffer, 3, '0', 4);
+        assertEquals("ABC000012", buffer.toString());
+        repeat(buffer, 6, ' ', 2);
+        assertEquals("ABC000  012", buffer.toString());
+        repeat(buffer, 6, '.', 3);
+        assertEquals("ABC000...  012", buffer.toString());
+    }
+
+    /**
      * Tests the {@link StringBuilders#trimFractionalPart(StringBuilder)} method.
      */
     @Test

Modified: sis/trunk/ide-project/NetBeans/build.xml
URL: http://svn.apache.org/viewvc/sis/trunk/ide-project/NetBeans/build.xml?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/ide-project/NetBeans/build.xml (original)
+++ sis/trunk/ide-project/NetBeans/build.xml Tue Mar  7 23:37:49 2017
@@ -44,6 +44,9 @@
       <fileset dir="${project.root}/core/sis-referencing/target/generated-resources">
         <include name="**/*.utf"/>
       </fileset>
+      <fileset dir="${project.root}/core/sis-referencing-by-identifiers/target/generated-resources">
+        <include name="**/*.utf"/>
+      </fileset>
       <fileset dir="${project.root}/core/sis-feature/target/generated-resources">
         <include name="**/*.utf"/>
       </fileset>

Modified: sis/trunk/ide-project/NetBeans/nbproject/build-impl.xml
URL: http://svn.apache.org/viewvc/sis/trunk/ide-project/NetBeans/nbproject/build-impl.xml?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/ide-project/NetBeans/nbproject/build-impl.xml (original)
+++ sis/trunk/ide-project/NetBeans/nbproject/build-impl.xml Tue Mar  7 23:37:49 2017
@@ -132,6 +132,7 @@ is divided into following sections:
                 <available file="${test.storage.dir}"/>
                 <available file="${test.feature.dir}"/>
                 <available file="${test.referencing.dir}"/>
+                <available file="${test.ref-by-id.dir}"/>
                 <available file="${test.metadata.dir}"/>
                 <available file="${test.utility.dir}"/>
                 <available file="${test.fra-profile.dir}"/>
@@ -150,6 +151,7 @@ is divided into following sections:
                 <available file="${src.storage.dir}"/>
                 <available file="${src.feature.dir}"/>
                 <available file="${src.referencing.dir}"/>
+                <available file="${src.ref-by-id.dir}"/>
                 <available file="${src.metadata.dir}"/>
                 <available file="${src.utility.dir}"/>
                 <available file="${src.fra-profile.dir}"/>
@@ -266,6 +268,7 @@ is divided into following sections:
         <fail unless="src.storage.dir">Must set src.storage.dir</fail>
         <fail unless="src.feature.dir">Must set src.feature.dir</fail>
         <fail unless="src.referencing.dir">Must set src.referencing.dir</fail>
+        <fail unless="src.ref-by-id.dir">Must set src.ref-by-id.dir</fail>
         <fail unless="src.metadata.dir">Must set src.metadata.dir</fail>
         <fail unless="src.utility.dir">Must set src.utility.dir</fail>
         <fail unless="src.fra-profile.dir">Must set src.fra-profile.dir</fail>
@@ -279,6 +282,7 @@ is divided into following sections:
         <fail unless="test.storage.dir">Must set test.storage.dir</fail>
         <fail unless="test.feature.dir">Must set test.feature.dir</fail>
         <fail unless="test.referencing.dir">Must set test.referencing.dir</fail>
+        <fail unless="test.ref-by-id.dir">Must set test.ref-by-id.dir</fail>
         <fail unless="test.metadata.dir">Must set test.metadata.dir</fail>
         <fail unless="test.utility.dir">Must set test.utility.dir</fail>
         <fail unless="test.fra-profile.dir">Must set test.fra-profile.dir</fail>
@@ -302,7 +306,7 @@ is divided into following sections:
     </target>
     <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-macrodef-javac-with-processors">
         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}" name="srcdir"/>
+            <attribute default="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.ref-by-id.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <attribute default="${javac.processorpath}" name="processorpath"/>
@@ -343,7 +347,7 @@ is divided into following sections:
     </target>
     <target depends="-init-ap-cmdline-properties" name="-init-macrodef-javac-without-processors" unless="ap.supported.internal">
         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}" name="srcdir"/>
+            <attribute default="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.ref-by-id.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <attribute default="${javac.processorpath}" name="processorpath"/>
@@ -376,7 +380,7 @@ is divided into following sections:
     </target>
     <target depends="-init-macrodef-javac-with-processors,-init-macrodef-javac-without-processors" name="-init-macrodef-javac">
         <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
-            <attribute default="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}" name="srcdir"/>
+            <attribute default="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.ref-by-id.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}" name="srcdir"/>
             <attribute default="${build.classes.dir}" name="destdir"/>
             <attribute default="${javac.classpath}" name="classpath"/>
             <sequential>
@@ -493,6 +497,9 @@ is divided into following sections:
                         <fileset dir="${test.referencing.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
                             <filename name="@{testincludes}"/>
                         </fileset>
+                        <fileset dir="${test.ref-by-id.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
+                            <filename name="@{testincludes}"/>
+                        </fileset>
                         <fileset dir="${test.metadata.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
                             <filename name="@{testincludes}"/>
                         </fileset>
@@ -561,6 +568,9 @@ is divided into following sections:
                     <fileset dir="${test.referencing.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">
                         <filename name="@{testincludes}"/>
                     </fileset>
+                    <fileset dir="${test.ref-by-id.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">
+                        <filename name="@{testincludes}"/>
+                    </fileset>
                     <fileset dir="${test.metadata.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">
                         <filename name="@{testincludes}"/>
                     </fileset>
@@ -709,6 +719,9 @@ is divided into following sections:
                         <fileset dir="${test.referencing.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
                             <filename name="@{testincludes}"/>
                         </fileset>
+                        <fileset dir="${test.ref-by-id.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
+                            <filename name="@{testincludes}"/>
+                        </fileset>
                         <fileset dir="${test.metadata.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
                             <filename name="@{testincludes}"/>
                         </fileset>
@@ -1082,7 +1095,7 @@ is divided into following sections:
                 <include name="*"/>
             </dirset>
         </pathconvert>
-        <j2seproject3:depend srcdir="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}:${build.generated.subdirs}"/>
+        <j2seproject3:depend srcdir="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.ref-by-id.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}:${build.generated.subdirs}"/>
     </target>
     <target depends="init,deps-jar,-pre-pre-compile,-pre-compile, -copy-persistence-xml,-compile-depend" if="have.sources" name="-do-compile">
         <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>
@@ -1098,6 +1111,7 @@ is divided into following sections:
             <fileset dir="${src.storage.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${src.feature.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${src.referencing.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${src.ref-by-id.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${src.metadata.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${src.utility.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${src.fra-profile.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
@@ -1121,7 +1135,7 @@ is divided into following sections:
     <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
         <j2seproject3:force-recompile/>
-        <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}"/>
+        <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.local-src.dir}:${src.webapp.dir}:${src.console.dir}:${src.earth-obs.dir}:${src.geotiff.dir}:${src.netcdf.dir}:${src.shapefile.dir}:${src.xmlstore.dir}:${src.storage.dir}:${src.feature.dir}:${src.referencing.dir}:${src.ref-by-id.dir}:${src.metadata.dir}:${src.utility.dir}:${src.fra-profile.dir}"/>
     </target>
     <target name="-post-compile-single">
         <!-- Empty placeholder for easier customization. -->
@@ -1420,6 +1434,9 @@ is divided into following sections:
             <fileset dir="${src.referencing.dir}" excludes="${bug5101868workaround},${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
+            <fileset dir="${src.ref-by-id.dir}" excludes="${bug5101868workaround},${excludes}" includes="${includes}">
+                <filename name="**/*.java"/>
+            </fileset>
             <fileset dir="${src.metadata.dir}" excludes="${bug5101868workaround},${excludes}" includes="${includes}">
                 <filename name="**/*.java"/>
             </fileset>
@@ -1469,6 +1486,9 @@ is divided into following sections:
             <fileset dir="${src.referencing.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
+            <fileset dir="${src.ref-by-id.dir}" excludes="${excludes}" includes="${includes}">
+                <filename name="**/doc-files/**"/>
+            </fileset>
             <fileset dir="${src.metadata.dir}" excludes="${excludes}" includes="${includes}">
                 <filename name="**/doc-files/**"/>
             </fileset>
@@ -1500,10 +1520,10 @@ is divided into following sections:
         <!-- You can override this target in the ../build.xml file. -->
     </target>
     <target if="do.depend.true" name="-compile-test-depend">
-        <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}"/>
+        <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.ref-by-id.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}"/>
     </target>
     <target depends="init,deps-jar,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
-        <j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" processorpath="${javac.test.processorpath}" srcdir="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}"/>
+        <j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" processorpath="${javac.test.processorpath}" srcdir="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.ref-by-id.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}"/>
         <copy todir="${build.test.classes.dir}">
             <fileset dir="${test.webapp.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.console.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
@@ -1515,6 +1535,7 @@ is divided into following sections:
             <fileset dir="${test.storage.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.feature.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.referencing.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${test.ref-by-id.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.metadata.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.utility.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.fra-profile.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
@@ -1532,7 +1553,7 @@ is divided into following sections:
     <target depends="init,deps-jar,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
         <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>
-        <j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" processorpath="${javac.test.processorpath}" sourcepath="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}" srcdir="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}"/>
+        <j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" processorpath="${javac.test.processorpath}" sourcepath="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.ref-by-id.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}" srcdir="${test.webapp.dir}:${test.console.dir}:${test.earth-obs.dir}:${test.geotiff.dir}:${test.netcdf.dir}:${test.shapefile.dir}:${test.xmlstore.dir}:${test.storage.dir}:${test.feature.dir}:${test.referencing.dir}:${test.ref-by-id.dir}:${test.metadata.dir}:${test.utility.dir}:${test.fra-profile.dir}"/>
         <copy todir="${build.test.classes.dir}">
             <fileset dir="${test.webapp.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.console.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
@@ -1544,6 +1565,7 @@ is divided into following sections:
             <fileset dir="${test.storage.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.feature.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.referencing.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
+            <fileset dir="${test.ref-by-id.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.metadata.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.utility.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
             <fileset dir="${test.fra-profile.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>

Modified: sis/trunk/ide-project/NetBeans/nbproject/genfiles.properties
URL: http://svn.apache.org/viewvc/sis/trunk/ide-project/NetBeans/nbproject/genfiles.properties?rev=1785905&r1=1785904&r2=1785905&view=diff
==============================================================================
--- sis/trunk/ide-project/NetBeans/nbproject/genfiles.properties [ISO-8859-1] (original)
+++ sis/trunk/ide-project/NetBeans/nbproject/genfiles.properties [ISO-8859-1] Tue Mar  7 23:37:49 2017
@@ -3,6 +3,6 @@
 build.xml.data.CRC32=58e6b21c
 build.xml.script.CRC32=462eaba0
 build.xml.stylesheet.CRC32=28e38971@1.53.1.46
-nbproject/build-impl.xml.data.CRC32=33837897
-nbproject/build-impl.xml.script.CRC32=895c1242
+nbproject/build-impl.xml.data.CRC32=7b029ee9
+nbproject/build-impl.xml.script.CRC32=d53d7c04
 nbproject/build-impl.xml.stylesheet.CRC32=830a3534@1.80.1.48



Mime
View raw message