You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sis.apache.org by de...@apache.org on 2023/08/29 17:47:51 UTC
[sis] branch geoapi-4.0 updated (c92fa5ad66 -> 350b496160)
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a change to branch geoapi-4.0
in repository https://gitbox.apache.org/repos/asf/sis.git
from c92fa5ad66 Add JUnit 5 in test dependencies for progressive migration. Opportunistically upgrade `ArgumentChecks` to JUnit 5, after its change for testing negative zeros.
new abafcba8a2 Skip the Ivy task if the "dependencies" directory is already present.
new 350b496160 Partial upgrade to ISO 19111:2019: replace some (not yet all) usages of deprecated `getScope()` and `getDomainOfValidity()` methods by `getDomains()`.
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../org.apache.sis.console/main/module-info.java | 2 +
.../org/apache/sis/console/TransformCommand.java | 17 +-
.../org.apache.sis.metadata/main/module-info.java | 2 +-
.../metadata/internal/ImplementationHelper.java | 8 +-
.../apache/sis/metadata/iso/extent/Extents.java | 47 ++++-
.../metadata/simple/SimpleIdentifiedObject.java | 6 +
.../metadata/replace/ReferenceSystemMetadata.java | 3 +-
.../apache/sis/util/iso/DefaultLocalNameTest.java | 2 +-
.../main/module-info.java | 3 +-
.../main/org/apache/sis/openoffice/CalcAddins.java | 2 +-
.../sis/openoffice/ReferencingFunctions.java | 37 ++--
.../main/org/apache/sis/io/wkt/Formatter.java | 59 ++++--
.../sis/referencing/AbstractIdentifiedObject.java | 227 ++++++++++++++++-----
.../sis/referencing/AbstractReferenceSystem.java | 183 ++---------------
.../main/org/apache/sis/referencing/CRS.java | 44 ++--
.../sis/referencing/DefaultObjectDomain.java | 221 ++++++++++++++++++++
.../apache/sis/referencing/IdentifiedObjects.java | 13 +-
.../org/apache/sis/referencing/NameIterator.java | 32 ++-
.../org/apache/sis/referencing/Properties.java | 87 ++++----
.../apache/sis/referencing/crs/AbstractCRS.java | 31 +--
.../sis/referencing/crs/DefaultCompoundCRS.java | 26 +--
.../sis/referencing/crs/DefaultDerivedCRS.java | 26 +--
.../sis/referencing/crs/DefaultEngineeringCRS.java | 26 +--
.../sis/referencing/crs/DefaultGeocentricCRS.java | 26 +--
.../sis/referencing/crs/DefaultGeographicCRS.java | 23 +--
.../sis/referencing/crs/DefaultImageCRS.java | 26 +--
.../sis/referencing/crs/DefaultParametricCRS.java | 26 +--
.../sis/referencing/crs/DefaultProjectedCRS.java | 26 +--
.../sis/referencing/crs/DefaultTemporalCRS.java | 26 +--
.../sis/referencing/crs/DefaultVerticalCRS.java | 26 +--
.../org/apache/sis/referencing/cs/AbstractCS.java | 12 +-
.../apache/sis/referencing/cs/AxesConvention.java | 12 +-
.../apache/sis/referencing/cs/DefaultAffineCS.java | 12 +-
.../sis/referencing/cs/DefaultCartesianCS.java | 12 +-
.../sis/referencing/cs/DefaultCompoundCS.java | 12 +-
.../cs/DefaultCoordinateSystemAxis.java | 24 +--
.../sis/referencing/cs/DefaultCylindricalCS.java | 12 +-
.../sis/referencing/cs/DefaultEllipsoidalCS.java | 12 +-
.../apache/sis/referencing/cs/DefaultLinearCS.java | 12 +-
.../sis/referencing/cs/DefaultParametricCS.java | 12 +-
.../apache/sis/referencing/cs/DefaultPolarCS.java | 12 +-
.../sis/referencing/cs/DefaultSphericalCS.java | 12 +-
.../apache/sis/referencing/cs/DefaultTimeCS.java | 12 +-
.../sis/referencing/cs/DefaultUserDefinedCS.java | 12 +-
.../sis/referencing/cs/DefaultVerticalCS.java | 12 +-
.../sis/referencing/datum/AbstractDatum.java | 129 ++----------
.../sis/referencing/datum/DefaultEllipsoid.java | 12 +-
.../referencing/datum/DefaultEngineeringDatum.java | 32 +--
.../sis/referencing/datum/DefaultImageDatum.java | 29 +--
.../referencing/datum/DefaultParametricDatum.java | 32 +--
.../referencing/datum/DefaultPrimeMeridian.java | 12 +-
.../referencing/datum/DefaultTemporalDatum.java | 32 +--
.../referencing/datum/DefaultVerticalDatum.java | 32 +--
.../referencing/factory/GeodeticObjectFactory.java | 54 ++---
.../operation/AbstractCoordinateOperation.java | 122 ++---------
.../operation/DefaultConcatenatedOperation.java | 26 +--
.../apache/sis/referencing/util/WKTKeywords.java | 3 +-
.../org/apache/sis/storage/base/Capability.java | 2 +-
.../main/org/apache/sis/setup/About.java | 2 +-
.../resources/ResourceInternationalString.java | 4 +-
.../org/apache/sis/util/resources/Vocabulary.java | 10 +-
.../sis/util/resources/Vocabulary.properties | 2 +-
.../sis/util/resources/Vocabulary_fr.properties | 2 +-
geoapi/snapshot | 2 +-
netbeans-project/build.xml | 7 +-
.../org/apache/sis/gui/dataset/WindowHandler.java | 2 +-
.../apache/sis/gui/internal/DataStoreOpener.java | 2 +-
.../org/apache/sis/gui/referencing/CRSChooser.java | 2 +-
68 files changed, 935 insertions(+), 1092 deletions(-)
create mode 100644 endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/DefaultObjectDomain.java
[sis] 02/02: Partial upgrade to ISO 19111:2019: replace some (not yet all) usages of deprecated `getScope()` and `getDomainOfValidity()` methods by `getDomains()`.
Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a commit to branch geoapi-4.0
in repository https://gitbox.apache.org/repos/asf/sis.git
commit 350b4961600c3f1b6b83cf98f3b7587da77d6bce
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Tue Aug 29 19:46:26 2023 +0200
Partial upgrade to ISO 19111:2019: replace some (not yet all) usages of deprecated `getScope()` and `getDomainOfValidity()` methods by `getDomains()`.
---
.../org.apache.sis.console/main/module-info.java | 2 +
.../org/apache/sis/console/TransformCommand.java | 17 +-
.../org.apache.sis.metadata/main/module-info.java | 2 +-
.../metadata/internal/ImplementationHelper.java | 8 +-
.../apache/sis/metadata/iso/extent/Extents.java | 47 ++++-
.../metadata/simple/SimpleIdentifiedObject.java | 6 +
.../metadata/replace/ReferenceSystemMetadata.java | 3 +-
.../apache/sis/util/iso/DefaultLocalNameTest.java | 2 +-
.../main/module-info.java | 3 +-
.../main/org/apache/sis/openoffice/CalcAddins.java | 2 +-
.../sis/openoffice/ReferencingFunctions.java | 37 ++--
.../main/org/apache/sis/io/wkt/Formatter.java | 59 ++++--
.../sis/referencing/AbstractIdentifiedObject.java | 227 ++++++++++++++++-----
.../sis/referencing/AbstractReferenceSystem.java | 183 ++---------------
.../main/org/apache/sis/referencing/CRS.java | 44 ++--
.../sis/referencing/DefaultObjectDomain.java | 221 ++++++++++++++++++++
.../apache/sis/referencing/IdentifiedObjects.java | 13 +-
.../org/apache/sis/referencing/NameIterator.java | 32 ++-
.../org/apache/sis/referencing/Properties.java | 87 ++++----
.../apache/sis/referencing/crs/AbstractCRS.java | 31 +--
.../sis/referencing/crs/DefaultCompoundCRS.java | 26 +--
.../sis/referencing/crs/DefaultDerivedCRS.java | 26 +--
.../sis/referencing/crs/DefaultEngineeringCRS.java | 26 +--
.../sis/referencing/crs/DefaultGeocentricCRS.java | 26 +--
.../sis/referencing/crs/DefaultGeographicCRS.java | 23 +--
.../sis/referencing/crs/DefaultImageCRS.java | 26 +--
.../sis/referencing/crs/DefaultParametricCRS.java | 26 +--
.../sis/referencing/crs/DefaultProjectedCRS.java | 26 +--
.../sis/referencing/crs/DefaultTemporalCRS.java | 26 +--
.../sis/referencing/crs/DefaultVerticalCRS.java | 26 +--
.../org/apache/sis/referencing/cs/AbstractCS.java | 12 +-
.../apache/sis/referencing/cs/AxesConvention.java | 12 +-
.../apache/sis/referencing/cs/DefaultAffineCS.java | 12 +-
.../sis/referencing/cs/DefaultCartesianCS.java | 12 +-
.../sis/referencing/cs/DefaultCompoundCS.java | 12 +-
.../cs/DefaultCoordinateSystemAxis.java | 24 +--
.../sis/referencing/cs/DefaultCylindricalCS.java | 12 +-
.../sis/referencing/cs/DefaultEllipsoidalCS.java | 12 +-
.../apache/sis/referencing/cs/DefaultLinearCS.java | 12 +-
.../sis/referencing/cs/DefaultParametricCS.java | 12 +-
.../apache/sis/referencing/cs/DefaultPolarCS.java | 12 +-
.../sis/referencing/cs/DefaultSphericalCS.java | 12 +-
.../apache/sis/referencing/cs/DefaultTimeCS.java | 12 +-
.../sis/referencing/cs/DefaultUserDefinedCS.java | 12 +-
.../sis/referencing/cs/DefaultVerticalCS.java | 12 +-
.../sis/referencing/datum/AbstractDatum.java | 129 ++----------
.../sis/referencing/datum/DefaultEllipsoid.java | 12 +-
.../referencing/datum/DefaultEngineeringDatum.java | 32 +--
.../sis/referencing/datum/DefaultImageDatum.java | 29 +--
.../referencing/datum/DefaultParametricDatum.java | 32 +--
.../referencing/datum/DefaultPrimeMeridian.java | 12 +-
.../referencing/datum/DefaultTemporalDatum.java | 32 +--
.../referencing/datum/DefaultVerticalDatum.java | 32 +--
.../referencing/factory/GeodeticObjectFactory.java | 54 ++---
.../operation/AbstractCoordinateOperation.java | 122 ++---------
.../operation/DefaultConcatenatedOperation.java | 26 +--
.../apache/sis/referencing/util/WKTKeywords.java | 3 +-
.../org/apache/sis/storage/base/Capability.java | 2 +-
.../main/org/apache/sis/setup/About.java | 2 +-
.../resources/ResourceInternationalString.java | 4 +-
.../org/apache/sis/util/resources/Vocabulary.java | 10 +-
.../sis/util/resources/Vocabulary.properties | 2 +-
.../sis/util/resources/Vocabulary_fr.properties | 2 +-
geoapi/snapshot | 2 +-
.../org/apache/sis/gui/dataset/WindowHandler.java | 2 +-
.../apache/sis/gui/internal/DataStoreOpener.java | 2 +-
.../org/apache/sis/gui/referencing/CRSChooser.java | 2 +-
67 files changed, 929 insertions(+), 1091 deletions(-)
diff --git a/endorsed/src/org.apache.sis.console/main/module-info.java b/endorsed/src/org.apache.sis.console/main/module-info.java
index cb5f883c5d..e564a8e00a 100644
--- a/endorsed/src/org.apache.sis.console/main/module-info.java
+++ b/endorsed/src/org.apache.sis.console/main/module-info.java
@@ -27,6 +27,8 @@ module org.apache.sis.console {
requires java.rmi;
requires java.management;
requires jakarta.xml.bind;
+
+ requires transitive org.apache.sis.util;
requires org.apache.sis.storage;
requires org.apache.sis.storage.xml;
diff --git a/endorsed/src/org.apache.sis.console/main/org/apache/sis/console/TransformCommand.java b/endorsed/src/org.apache.sis.console/main/org/apache/sis/console/TransformCommand.java
index 536a4b1392..122bd10076 100644
--- a/endorsed/src/org.apache.sis.console/main/org/apache/sis/console/TransformCommand.java
+++ b/endorsed/src/org.apache.sis.console/main/org/apache/sis/console/TransformCommand.java
@@ -18,6 +18,7 @@ package org.apache.sis.console;
import java.util.List;
import java.util.ArrayList;
+import java.util.Collection;
import java.util.EnumSet;
import java.util.Locale;
import java.io.IOException;
@@ -75,13 +76,16 @@ import org.apache.sis.util.logging.Logging;
import static java.util.logging.Logger.getLogger;
+// Specific to the geoapi-3.1 and geoapi-4.0 branches:
+import org.opengis.referencing.ObjectDomain;
+
/**
* The "transform" subcommand.
* The output is a comma separated values (CSV) file, with {@code '#'} as the first character of comment lines.
*
* @author Martin Desruisseaux (Geomatys)
- * @version 0.8
+ * @version 1.4
* @since 0.7
*/
final class TransformCommand extends FormattedOutputCommand {
@@ -234,7 +238,7 @@ final class TransformCommand extends FormattedOutputCommand {
printHeader(Vocabulary.Keys.Destination); printNameAndIdentifier(operation.getTargetCRS(), false);
printHeader(Vocabulary.Keys.Operations); printOperations (operation, false);
outHeader.nextLine();
- printDomainOfValidity(operation.getDomainOfValidity());
+ printDomainOfValidity(operation.getDomains());
printAccuracy(CRS.getLinearAccuracy(operation));
if (options.containsKey(Option.VERBOSE)) {
printDetails();
@@ -383,9 +387,10 @@ final class TransformCommand extends FormattedOutputCommand {
*
* <blockquote>Canada - onshore and offshore</blockquote>
*/
- private void printDomainOfValidity(final Extent domain) throws IOException {
- if (domain != null) {
- final InternationalString description = domain.getDescription();
+ private void printDomainOfValidity(final Collection<ObjectDomain> domains) throws IOException {
+ for (final ObjectDomain domain : domains) {
+ final Extent extent = domain.getDomainOfValidity();
+ final InternationalString description = extent.getDescription();
if (description != null) {
String text = description.toString(locale);
if (text.length() >= 80) {
@@ -401,6 +406,7 @@ final class TransformCommand extends FormattedOutputCommand {
printHeader(Vocabulary.Keys.Domain);
outHeader.append(text);
outHeader.nextLine();
+ return;
}
}
}
@@ -410,7 +416,6 @@ final class TransformCommand extends FormattedOutputCommand {
* This information is printed only if the {@code --verbose} option was specified.
*/
private void printDetails() throws IOException {
- final boolean debug = options.containsKey(Option.DEBUG);
final WKTFormat f = new WKTFormat(locale, timezone);
if (colors) f.setColors(Colors.DEFAULT);
f.setConvention(convention);
diff --git a/endorsed/src/org.apache.sis.metadata/main/module-info.java b/endorsed/src/org.apache.sis.metadata/main/module-info.java
index e120513b92..d9a14d16c5 100644
--- a/endorsed/src/org.apache.sis.metadata/main/module-info.java
+++ b/endorsed/src/org.apache.sis.metadata/main/module-info.java
@@ -30,8 +30,8 @@ module org.apache.sis.metadata {
/*
* Dependencies. Only the ones that appear in public API should be transitive.
*/
- requires java.sql;
requires java.naming;
+ requires transitive java.sql;
requires transitive jakarta.xml.bind;
requires transitive org.apache.sis.util;
diff --git a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/internal/ImplementationHelper.java b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/internal/ImplementationHelper.java
index de6bedbea3..f0516b2311 100644
--- a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/internal/ImplementationHelper.java
+++ b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/internal/ImplementationHelper.java
@@ -185,10 +185,10 @@ public final class ImplementationHelper extends Static {
* warning or error messages in future SIS versions.</li>
* </ul>
*
- * @param classe the caller class, used only in case of warning message to log.
- * @param method the caller method, used only in case of warning message to log.
- * @param name the property name, used only in case of error message to format.
- * @throws IllegalStateException if {@code isDefined} is {@code true} and we are not unmarshalling an object.
+ * @param classe the caller class, used for logging.
+ * @param method the caller method, used for logging.
+ * @param name the property name, used for logging and exception message.
+ * @throws IllegalStateException if we are not unmarshalling an object.
*
* @since 0.7
*/
diff --git a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/iso/extent/Extents.java b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/iso/extent/Extents.java
index a7c2905491..f1c9cec939 100644
--- a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/iso/extent/Extents.java
+++ b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/iso/extent/Extents.java
@@ -68,7 +68,10 @@ import static org.apache.sis.util.internal.CollectionsExt.nonNull;
import static org.apache.sis.metadata.internal.ReferencingServices.AUTHALIC_RADIUS;
// Specific to the geoapi-3.1 and geoapi-4.0 branches:
+import java.util.Optional;
+import org.opengis.referencing.ObjectDomain;
import org.opengis.geometry.MismatchedReferenceSystemException;
+import org.opengis.referencing.operation.CoordinateOperation;
/**
@@ -84,7 +87,7 @@ import org.opengis.geometry.MismatchedReferenceSystemException;
* </ul>
*
* @author Martin Desruisseaux (Geomatys)
- * @version 1.3
+ * @version 1.4
*
* @see org.apache.sis.geometry.Envelopes
*
@@ -205,6 +208,46 @@ public final class Extents extends Static {
return m.bounds;
}
+ /**
+ * Returns a single geographic bounding box for the given domains of validity.
+ * For each domain, the bounding box is fetched with {@link #getGeographicBoundingBox(Extent)}.
+ * If more than one geographic domain of validity is found, this method computes their union.
+ *
+ * <p>This is a convenience method for fetching the domain of validity of {@link Datum},
+ * {@link CoordinateReferenceSystem} or {@link CoordinateOperation} objects.</p>
+ *
+ * @param domains the domains of validity for which to get a single geographic bounding box, or {@code null}.
+ * @return the union of all geographic bounding boxes found in all domains of validity.
+ * @throws InvalidMetadataException if an envelope cannot be transformed to a geographic bounding box.
+ *
+ * @see CoordinateReferenceSystem#getDomains()
+ * @see org.apache.sis.referencing.CRS#getDomainOfValidity(CoordinateReferenceSystem)
+ *
+ * @since 1.4
+ */
+ public static Optional<GeographicBoundingBox> getGeographicBoundingBox(final Iterable<? extends ObjectDomain> domains) {
+ if (domains != null) {
+ Extents m = null;
+ for (final ObjectDomain domain : domains) {
+ final Extent extent = domain.getDomainOfValidity();
+ if (extent != null) {
+ if (m == null) {
+ m = new Extents();
+ }
+ try {
+ m.addHorizontal(extent);
+ } catch (TransformException e) {
+ throw new InvalidMetadataException(Errors.format(Errors.Keys.CanNotTransformEnvelope), e);
+ }
+ }
+ }
+ if (m != null) {
+ return Optional.ofNullable(m.bounds);
+ }
+ }
+ return Optional.empty();
+ }
+
/**
* Returns a single geographic bounding box from the specified extent.
* This method tries to find the bounding box in the cheapest way
@@ -228,6 +271,7 @@ public final class Extents extends Static {
*
* @param extent the extent to convert to a geographic bounding box, or {@code null}.
* @return a geographic bounding box extracted from the given extent, or {@code null} if none.
+ * @throws InvalidMetadataException if an envelope cannot be transformed to a geographic bounding box.
*
* @see org.apache.sis.referencing.CRS#getDomainOfValidity(CoordinateReferenceSystem)
*/
@@ -250,6 +294,7 @@ public final class Extents extends Static {
* Defined in as a class member for allowing accumulation of many extents.
*
* @param extent the extent to add. Must be non-null.
+ * @throws TransformException if an envelope cannot be transformed to a geographic bounding box.
*/
private void addHorizontal(final Extent extent) throws TransformException {
boolean useOnlyGeographicEnvelopes = false;
diff --git a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/simple/SimpleIdentifiedObject.java b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/simple/SimpleIdentifiedObject.java
index ba0a000168..d1a948204e 100644
--- a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/simple/SimpleIdentifiedObject.java
+++ b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/simple/SimpleIdentifiedObject.java
@@ -110,7 +110,10 @@ public class SimpleIdentifiedObject implements IdentifiedObject, LenientComparab
* revisit {@link #equals(Object, ComparisonMode)} in subclasses.</p>
*
* @return the scope, or {@code null} if none.
+ *
+ * @deprecated Removed from ISO 19111:2019 (moved to {@code ObjectDomain}).
*/
+ @Deprecated
public final InternationalString getScope() {
return null;
}
@@ -120,7 +123,10 @@ public class SimpleIdentifiedObject implements IdentifiedObject, LenientComparab
* The default implementation returns {@link Identifier#getDescription()}.
*
* @return a narrative explanation of the role of this object, or {@code null} if none.
+ *
+ * @deprecated Removed from ISO 19111:2019 (moved to {@code ObjectDomain}).
*/
+ @Deprecated
public InternationalString getDescription() {
final Identifier name = this.name;
return (name != null) ? name.getDescription() : null;
diff --git a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/xml/bind/metadata/replace/ReferenceSystemMetadata.java b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/xml/bind/metadata/replace/ReferenceSystemMetadata.java
index 13974c194a..8ee59f4dda 100644
--- a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/xml/bind/metadata/replace/ReferenceSystemMetadata.java
+++ b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/xml/bind/metadata/replace/ReferenceSystemMetadata.java
@@ -26,6 +26,7 @@ import org.apache.sis.xml.Namespaces;
import org.apache.sis.xml.bind.FilterByVersion;
import org.apache.sis.util.ComparisonMode;
import org.apache.sis.util.Utilities;
+import org.apache.sis.util.collection.Containers;
// Specific to the geoapi-4.0 branch:
import org.opengis.metadata.Identifier;
@@ -146,7 +147,7 @@ public class ReferenceSystemMetadata extends SimpleIdentifiedObject implements R
// Compare the name because it was ignored by super.equals(…) in "ignore metadata" mode.
return Utilities.deepEquals(getName(), that.getName(), mode);
}
- return that.getDomainOfValidity() == null && that.getScope() == null;
+ return Containers.isNullOrEmpty(that.getDomains());
}
return false;
}
diff --git a/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/util/iso/DefaultLocalNameTest.java b/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/util/iso/DefaultLocalNameTest.java
index 6b71cee384..951b2d7e2b 100644
--- a/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/util/iso/DefaultLocalNameTest.java
+++ b/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/util/iso/DefaultLocalNameTest.java
@@ -65,7 +65,7 @@ public final class DefaultLocalNameTest extends TestCase {
public void testEpsgNamespace() {
final DefaultNameSpace ns = DefaultNameSpace.forName(new DefaultLocalName(null, EPSG),
DEFAULT_SEPARATOR_STRING, DEFAULT_SEPARATOR_STRING);
- assertSame(EPSG, ns.name().toString());
+ assertEquals(EPSG, ns.name().toString());
validate(ns); // GeoAPI tests.
final String WGS84 = "4326";
diff --git a/endorsed/src/org.apache.sis.openoffice/main/module-info.java b/endorsed/src/org.apache.sis.openoffice/main/module-info.java
index 6364577884..a18c6704a8 100644
--- a/endorsed/src/org.apache.sis.openoffice/main/module-info.java
+++ b/endorsed/src/org.apache.sis.openoffice/main/module-info.java
@@ -23,7 +23,8 @@
* @since 0.3
*/
module org.apache.sis.openoffice {
- requires static org.libreoffice.uno;
+ requires transitive java.logging;
+ requires transitive static org.libreoffice.uno;
requires org.apache.sis.referencing;
requires org.apache.sis.storage;
diff --git a/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/CalcAddins.java b/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/CalcAddins.java
index e73d26dfc6..1e352e5c85 100644
--- a/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/CalcAddins.java
+++ b/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/CalcAddins.java
@@ -147,7 +147,7 @@ public abstract class CalcAddins extends WeakBase implements XServiceName, XServ
* @return the string with a message for missing values.
*/
final String noResultString() {
- return Vocabulary.getResources(getJavaLocale()).getString(Vocabulary.Keys.Unknown);
+ return Vocabulary.getResources(getJavaLocale()).getString(Vocabulary.Keys.NotKnown);
}
/**
diff --git a/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/ReferencingFunctions.java b/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/ReferencingFunctions.java
index 2acf4f97ee..cc71c320ee 100644
--- a/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/ReferencingFunctions.java
+++ b/endorsed/src/org.apache.sis.openoffice/main/org/apache/sis/openoffice/ReferencingFunctions.java
@@ -22,6 +22,7 @@ import org.opengis.util.InternationalString;
import org.opengis.metadata.extent.Extent;
import org.opengis.metadata.extent.GeographicBoundingBox;
import org.opengis.referencing.IdentifiedObject;
+import org.opengis.referencing.ObjectDomain;
import org.opengis.referencing.ReferenceSystem;
import org.opengis.referencing.cs.CoordinateSystem;
import org.opengis.referencing.cs.CoordinateSystemAxis;
@@ -31,7 +32,6 @@ import com.sun.star.uno.XComponentContext;
import com.sun.star.lang.IllegalArgumentException;
import org.apache.sis.metadata.iso.extent.Extents;
import org.apache.sis.referencing.CRS;
-import org.apache.sis.referencing.IdentifiedObjects;
import org.apache.sis.referencing.AbstractIdentifiedObject;
import org.apache.sis.io.wkt.Transliterator;
import org.apache.sis.util.Classes;
@@ -190,12 +190,16 @@ public class ReferencingFunctions extends CalcAddins implements XReferencing {
final Object value;
try {
final IdentifiedObject object = getIdentifiedObject(codeOrPath, null);
- value = IdentifiedObjects.getProperties(object).get(ReferenceSystem.SCOPE_KEY);
+ for (final ObjectDomain domain : object.getDomains()) {
+ InternationalString scope = domain.getScope();
+ if (scope != null) {
+ return scope.toString(getJavaLocale());
+ }
+ }
} catch (Exception exception) {
return getLocalizedMessage(exception);
}
- return (value instanceof InternationalString)
- ? ((InternationalString) value).toString(getJavaLocale()) : noResultString();
+ return noResultString();
}
/**
@@ -206,19 +210,20 @@ public class ReferencingFunctions extends CalcAddins implements XReferencing {
*/
@Override
public String getDomainOfValidity(final String codeOrPath) {
- final Object domain;
try {
final IdentifiedObject object = getIdentifiedObject(codeOrPath, null);
- domain = IdentifiedObjects.getProperties(object).get(ReferenceSystem.DOMAIN_OF_VALIDITY_KEY);
+ for (final ObjectDomain domain : object.getDomains()) {
+ final Extent extent = domain.getDomainOfValidity();
+ if (extent != null) {
+ final InternationalString description = extent.getDescription();
+ if (description != null) {
+ return description.toString(getJavaLocale());
+ }
+ }
+ }
} catch (Exception exception) {
return getLocalizedMessage(exception);
}
- if (domain instanceof Extent) {
- final InternationalString description = ((Extent) domain).getDescription();
- if (description != null) {
- return description.toString(getJavaLocale());
- }
- }
return noResultString();
}
@@ -242,9 +247,11 @@ public class ReferencingFunctions extends CalcAddins implements XReferencing {
area = handler.peek();
if (area == null) try {
final IdentifiedObject object = getIdentifiedObject(codeOrPath, null);
- final Object domain = IdentifiedObjects.getProperties(object).get(ReferenceSystem.DOMAIN_OF_VALIDITY_KEY);
- if (domain instanceof Extent) {
- area = Extents.getGeographicBoundingBox((Extent) domain);
+ for (final ObjectDomain domain : object.getDomains()) {
+ area = Extents.getGeographicBoundingBox(domain.getDomainOfValidity());
+ if (area != null) {
+ break;
+ }
}
} catch (Exception exception) {
reportException("getGeographicArea", exception);
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/io/wkt/Formatter.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/io/wkt/Formatter.java
index a8c44f423b..f27c538f41 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/io/wkt/Formatter.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/io/wkt/Formatter.java
@@ -80,6 +80,7 @@ import org.apache.sis.metadata.simple.SimpleExtent;
import org.apache.sis.metadata.internal.Resources;
import org.apache.sis.referencing.AbstractIdentifiedObject;
import org.apache.sis.referencing.ImmutableIdentifier;
+import org.apache.sis.referencing.DefaultObjectDomain;
import org.apache.sis.referencing.util.WKTKeywords;
import org.apache.sis.referencing.util.WKTUtilities;
import org.apache.sis.geometry.AbstractDirectPosition;
@@ -88,6 +89,7 @@ import org.apache.sis.metadata.iso.extent.Extents;
// Specific to the geoapi-3.1 and geoapi-4.0 branches:
import org.opengis.util.ControlledVocabulary;
+import org.opengis.referencing.ObjectDomain;
/**
@@ -105,7 +107,7 @@ import org.opengis.util.ControlledVocabulary;
* </ul>
*
* @author Martin Desruisseaux (IRD, Geomatys)
- * @version 1.1
+ * @version 1.4
*
* @see <a href="http://docs.opengeospatial.org/is/12-063r5/12-063r5.html">WKT 2 specification</a>
* @see <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/doc-files/WKT.html">Legacy WKT 1</a>
@@ -877,30 +879,49 @@ public class Formatter implements Localized {
}
/**
- * Appends the anchor, scope and domain of validity of the given object. Those information are available
- * only for {@link ReferenceSystem}, {@link Datum} and {@link CoordinateOperation} objects.
+ * Appends the anchor, scope and domain of validity of the given object.
+ * In the ISO 19111 model, those information are valid only for {@link Datum},
+ * {@link ReferenceSystem} and {@link CoordinateOperation} objects.
*/
private void appendForSubtypes(final IdentifiedObject object) {
- final InternationalString anchor, scope;
- final Extent area;
- if (object instanceof ReferenceSystem) {
- anchor = null;
- scope = ((ReferenceSystem) object).getScope();
- area = ((ReferenceSystem) object).getDomainOfValidity();
- } else if (object instanceof Datum) {
+ InternationalString anchor = null, scope = null;
+ Extent area = null;
+ if (object instanceof Datum) {
anchor = ((Datum) object).getAnchorPoint();
- scope = ((Datum) object).getScope();
- area = ((Datum) object).getDomainOfValidity();
- } else if (object instanceof CoordinateOperation) {
- anchor = null;
- scope = ((CoordinateOperation) object).getScope();
- area = ((CoordinateOperation) object).getDomainOfValidity();
- } else {
+ } else if (!(object instanceof ReferenceSystem || object instanceof CoordinateOperation)) {
return;
}
+ for (final ObjectDomain domain : object.getDomains()) {
+ scope = domain.getScope();
+ area = domain.getDomainOfValidity();
+ if (area != null) break;
+ // TODO: in 2019 revision we need to format all USAGE[…] elements, not only the first one.
+ }
appendOnNewLine(WKTKeywords.Anchor, anchor, null);
- appendOnNewLine(WKTKeywords.Scope, scope, ElementKind.SCOPE);
- if (area != null) {
+ append(scope, area);
+ }
+
+ /**
+ * Appends the usage (scope and domain of validity) of an object.
+ * The arguments are the components of an {@link ObjectDomain}.
+ * The given extent is decomposed in horizontal, vertical and temporal components.
+ * The horizontal component uses the default number of fraction digits recommended by ISO 19162.
+ *
+ * <h4>Usage element</h4>
+ * In a WKT string, the given elements should be enclosed in an {@code USAGE[…]} element
+ * according the ISO 19162:2019 standard but not according the previous version (2015).
+ * The {@code USAGE[…]} enclosing element shall be provided when needed by the caller.
+ *
+ * @param scope description of domain of usage, or {@code null} if none.
+ * @param area area for which the object is valid, or {@code null} if none.
+ *
+ * @since 1.4
+ */
+ public void append(final InternationalString scope, final Extent area) {
+ if (DefaultObjectDomain.isDefined(scope)) {
+ appendOnNewLine(WKTKeywords.Scope, scope, ElementKind.SCOPE);
+ }
+ if (DefaultObjectDomain.isDefined(area)) {
appendOnNewLine(WKTKeywords.Area, area.getDescription(), ElementKind.EXTENT);
append(Extents.getGeographicBoundingBox(area), BBOX_ACCURACY);
appendVerticalExtent(Extents.getVerticalRange(area));
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractIdentifiedObject.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractIdentifiedObject.java
index 2b0641d06b..0814928ad3 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractIdentifiedObject.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractIdentifiedObject.java
@@ -26,6 +26,8 @@ import java.util.Locale;
import java.util.Objects;
import java.util.Formattable;
import java.util.FormattableFlags;
+import java.util.function.Function;
+import java.util.function.Predicate;
import java.io.Serializable;
import jakarta.xml.bind.annotation.XmlID;
import jakarta.xml.bind.annotation.XmlType;
@@ -38,18 +40,22 @@ import jakarta.xml.bind.annotation.adapters.CollapsedStringAdapter;
import org.opengis.util.GenericName;
import org.opengis.util.InternationalString;
import org.opengis.metadata.Identifier;
+import org.opengis.metadata.extent.Extent;
import org.opengis.metadata.citation.Citation;
import org.opengis.referencing.ObjectFactory;
import org.opengis.referencing.AuthorityFactory;
import org.opengis.referencing.IdentifiedObject;
+import org.opengis.referencing.ReferenceSystem;
import org.apache.sis.xml.Namespaces;
-import org.apache.sis.xml.bind.Context;
import org.apache.sis.xml.bind.UseLegacyMetadata;
import org.apache.sis.xml.bind.referencing.Code;
+import org.apache.sis.xml.bind.metadata.EX_Extent;
import org.apache.sis.util.Deprecable;
import org.apache.sis.util.ComparisonMode;
import org.apache.sis.util.LenientComparable;
+import org.apache.sis.util.Workaround;
import org.apache.sis.util.Classes;
+import org.apache.sis.util.collection.Containers;
import org.apache.sis.util.internal.Strings;
import org.apache.sis.util.internal.UnmodifiableArrayList;
import org.apache.sis.metadata.internal.NameToIdentifier;
@@ -61,6 +67,7 @@ import org.apache.sis.io.wkt.ElementKind;
import org.apache.sis.util.iso.Types;
import org.apache.sis.util.iso.DefaultNameFactory;
import org.apache.sis.util.resources.Errors;
+import org.apache.sis.util.internal.CollectionsExt;
import static org.apache.sis.util.ArgumentChecks.*;
import static org.apache.sis.util.Utilities.deepEquals;
@@ -68,6 +75,9 @@ import static org.apache.sis.util.internal.CollectionsExt.nonNull;
import static org.apache.sis.util.internal.CollectionsExt.nonEmpty;
import static org.apache.sis.util.internal.CollectionsExt.immutableSet;
+// Specific to the geoapi-3.1 and geoapi-4.0 branches:
+import org.opengis.referencing.ObjectDomain;
+
/**
* Base class for objects identified by a name or a code. Those objects are typically
@@ -124,7 +134,9 @@ import static org.apache.sis.util.internal.CollectionsExt.immutableSet;
"description",
"identifier",
"names",
- "remarks"
+ "remarks",
+ "domain", // GML defines "domainOfValidity" in Datum, AbstractCRS and AbstractCoordinateOperation.
+ "domainScope" // GML defines "scope" in same classes than above.
})
@XmlSeeAlso({
org.apache.sis.referencing.crs.AbstractCRS.class,
@@ -203,6 +215,20 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
@SuppressWarnings("serial") // Most SIS implementations are serializable.
private Set<Identifier> identifiers;
+ /**
+ * Scope and area for which this object is valid, or {@code null} if none.
+ * We must be prepared to handle either null or an empty set for "domains"
+ * because we may get both on unmarshalling.
+ *
+ * <p><b>Consider this field as final!</b>
+ * This field is modified only at unmarshalling time by {@link #setScope(InternationalString)}
+ * and {@link #setDomainOfValidity(Extent)}.</p>
+ *
+ * @see #getDomains()
+ */
+ @SuppressWarnings("serial") // Most SIS implementations are serializable.
+ private Collection<ObjectDomain> domains;
+
/**
* Comments on or information about this object, or {@code null} if none.
*
@@ -235,9 +261,7 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
* {@value org.opengis.referencing.IdentifiedObject#NAME_KEY} or
* {@value org.opengis.metadata.Identifier#CODE_KEY} key.
* Other properties listed in the table below are optional.
- * In particular, {@code "authority"}, {@code "code"}, {@code "codespace"} and {@code "version"}
- * are convenience properties for building a name, and are ignored if the {@code "name"} property
- * is already a {@link Identifier} object instead of a {@link String}.
+ * Some properties are shortcuts discussed below the table.
*
* <table class="sis">
* <caption>Recognized properties (non exhaustive list)</caption>
@@ -245,64 +269,72 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#AUTHORITY_KEY}</td>
* <td>{@link String} or {@link Citation}</td>
* <td>{@link NamedIdentifier#getAuthority()} on the {@linkplain #getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#CODE_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getCode()} on the {@linkplain #getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#CODESPACE_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getCodeSpace()} on the {@linkplain #getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#VERSION_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getVersion()} on the {@linkplain #getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#DESCRIPTION_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getDescription()} on the {@linkplain #getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
+ * <td>{@link String} or {@link InternationalString}</td>
+ * <td>{@link ObjectDomain#getScope()} on the {@linkplain #getDomains() domain}</td>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
+ * <td>{@link Extent}</td>
+ * <td>{@link ObjectDomain#getDomainOfValidity()} on the {@linkplain #getDomains() domain}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value #DEPRECATED_KEY}</td>
* <td>{@link Boolean}</td>
* <td>{@link #isDeprecated()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value #LOCALE_KEY}</td>
* <td>{@link Locale}</td>
* <td>(none)</td>
* </tr>
* </table>
*
+ * <h4>Shortcuts</h4>
+ * The {@code "authority"}, {@code "code"}, {@code "codespace"} and {@code "version"} properties
+ * are shortcuts for building a name. Their values are ignored if the {@code "name"} property is
+ * already associated to an {@link Identifier} value instead of a {@link String}. Likewise, the
+ * {@code "scope"} and {@code "domainOfValidity"} shortcuts are ignored if the {@code "domains"}
+ * property is provided.
+ *
* <h4>Localization</h4>
* All localizable attributes like {@code "remarks"} may have a language and country code suffix.
* For example, the {@code "remarks_fr"} property stands for remarks in {@linkplain Locale#FRENCH French} and
@@ -357,16 +389,33 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
// "identifiers": Identifier or Identifier[]
// -----------------------------------------
value = properties.get(IDENTIFIERS_KEY);
- if (value == null) {
- identifiers = null;
- } else if (value instanceof Identifier) {
+ if (value instanceof Identifier) {
identifiers = Collections.singleton((Identifier) value);
} else if (value instanceof Identifier[]) {
identifiers = immutableSet(true, (Identifier[]) value);
- } else {
+ } else if (value != null) {
throw illegalPropertyType(properties, IDENTIFIERS_KEY, value);
}
+ // -----------------------------------------
+ // "domains": ObjectDomain or ObjectDomain[]
+ // -----------------------------------------
+ value = properties.get(DOMAINS_KEY);
+ if (value instanceof ObjectDomain) {
+ domains = Collections.singleton((ObjectDomain) value);
+ } else if (value instanceof ObjectDomain[]) {
+ domains = immutableSet(true, (ObjectDomain[]) value);
+ } else if (value != null) {
+ throw illegalPropertyType(properties, DOMAINS_KEY, value);
+ } else {
+ // Compatibility with previous way to specify domain.
+ final InternationalString scope = Types.toInternationalString(properties, ReferenceSystem.SCOPE_KEY);
+ final Extent domainOfValidity = Containers.property(properties, ReferenceSystem.DOMAIN_OF_VALIDITY_KEY, Extent.class);
+ if (scope != null || domainOfValidity != null) {
+ domains = Collections.singleton(new DefaultObjectDomain(scope, domainOfValidity));
+ }
+ }
+
// ----------------------------------------
// "remarks": String or InternationalString
// ----------------------------------------
@@ -409,6 +458,7 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
name = object.getName();
alias = nonEmpty(object.getAlias()); // Favor null for empty set in case it is not Collections.EMPTY_SET
identifiers = nonEmpty(object.getIdentifiers());
+ domains = nonEmpty(object.getDomains());
remarks = object.getRemarks();
deprecated = (object instanceof Deprecable) ? ((Deprecable) object).isDeprecated() : false;
}
@@ -509,6 +559,20 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
return nonNull(identifiers); // Needs to be null-safe because we may have a null value on unmarshalling.
}
+ /**
+ * Returns the usage of this CRS-related object.
+ * The domain includes a scope (description of the primary purpose of this object) together
+ * with a domain of validity (spatial and temporal extent in which the object can be used).
+ *
+ * @return scopes and domains of validity of this object.
+ *
+ * @since 1.4
+ */
+ @Override
+ public Collection<ObjectDomain> getDomains() {
+ return nonNull(domains);
+ }
+
/**
* Returns a narrative explanation of the role of this object.
*
@@ -706,9 +770,11 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
}
}
}
- return Objects.equals(name, that.name) &&
+ return deprecated == that.deprecated &&
+ Objects.equals(name, that.name) &&
nonNull(alias).equals(nonNull(that.alias)) &&
nonNull(identifiers).equals(nonNull(that.identifiers)) &&
+ nonNull(domains).equals(nonNull(that.domains)) &&
Objects.equals(remarks, that.remarks);
}
case BY_CONTRACT: {
@@ -719,6 +785,7 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
return deepEquals(getName(), that.getName(), mode) &&
deepEquals(getAlias(), that.getAlias(), mode) &&
deepEquals(getIdentifiers(), that.getIdentifiers(), mode) &&
+ deepEquals(getDomains(), that.getDomains(), mode) &&
deepEquals(getRemarks(), that.getRemarks(), mode);
}
case IGNORE_METADATA:
@@ -825,7 +892,8 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
* @return the hash code value. This value may change in any future Apache SIS version.
*/
protected long computeHashCode() {
- return Objects.hash(name, nonNull(alias), nonNull(identifiers), remarks) ^ getInterface().hashCode();
+ return Objects.hash(name, nonNull(alias), nonNull(identifiers), nonNull(domains), deprecated, remarks)
+ ^ getInterface().hashCode();
}
/**
@@ -958,7 +1026,7 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
final String getID() {
// Implementation is provided in the NameIterator class for reducing the size of
// AbstractIdentifiedObject.class file in the common case where XML is not needed.
- return NameIterator.getID(Context.current(), this, name, alias, identifiers);
+ return NameIterator.getID(this, name, alias, identifiers);
}
/**
@@ -969,10 +1037,7 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
* from elsewhere in the XML document.
*/
private void setID(final String id) {
- final Context context = Context.current();
- if (!Context.setObjectForID(context, this, id)) {
- Context.warningOccured(context, getClass(), "setID", Errors.class, Errors.Keys.DuplicatedIdentifier_1, id);
- }
+ NameIterator.setID(this, id);
}
/**
@@ -996,15 +1061,13 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
* Invoked by JAXB at unmarshalling time for setting the identifier.
*/
private void setIdentifier(final Code identifier) {
- if (identifiers == null) {
- if (identifier != null) {
- final Identifier id = identifier.getIdentifier();
- if (id != null) {
- identifiers = Collections.singleton(id);
- }
- }
- } else {
+ if (identifiers != null) {
ImplementationHelper.propertyAlreadySet(AbstractIdentifiedObject.class, "setIdentifier", "identifier");
+ } else if (identifier != null) {
+ final Identifier id = identifier.getIdentifier();
+ if (id != null) {
+ identifiers = Collections.singleton(id);
+ }
}
}
@@ -1114,6 +1177,78 @@ public class AbstractIdentifiedObject extends FormattableObject implements Ident
}
}
+ /**
+ * Finds the first non-null domain element.
+ *
+ * @param <T> type of domain element to get.
+ * @param getter {@link ObjectDomain} getter method to invoke.
+ * @param predicate the non-null and non-undefined check.
+ * @return first non-null value, or {@code null} if none.
+ */
+ private <T> T findFirst(final Function<ObjectDomain,T> getter, final Predicate<T> isDefined) {
+ if (domains == null) return null;
+ return domains.stream().map(getter).filter(isDefined).findFirst().orElse(null);
+ }
+
+ /**
+ * Returns the region or timeframe in which this object is valid, or {@code null} if unspecified.
+ * This is used for JAXB marshalling only.
+ *
+ * @return area or region or timeframe in which this object is valid, or {@code null}.
+ */
+ @XmlElement(name = "domainOfValidity")
+ // For an unknown reason, JAXB does not take the adapter declared in package-info for this particular property.
+ @Workaround(library = "JDK", version = "1.8")
+ @XmlJavaTypeAdapter(EX_Extent.class)
+ private Extent getDomain() {
+ return findFirst(ObjectDomain::getDomainOfValidity, DefaultObjectDomain::isDefined);
+ }
+
+ /**
+ * Returns the domain or limitations of usage, or {@code null} if unspecified.
+ * This is used for JAXB marshalling only. This property is mandatory in datum,
+ * coordinate reference system and coordinate operation but is not expected in
+ * other kind of objects, so we declare it as optional.
+ *
+ * @return description of domain of usage, or {@code null}.
+ */
+ @XmlElement(name ="scope")
+ private InternationalString getDomainScope() {
+ return findFirst(ObjectDomain::getScope, DefaultObjectDomain::isDefined);
+ }
+
+ /**
+ * Invoked by JAXB only at unmarshalling time.
+ */
+ private void setDomain(final Extent value) {
+ InternationalString scope = null;
+ final ObjectDomain domain = CollectionsExt.first(domains);
+ if (domain != null) {
+ if (DefaultObjectDomain.isDefined(domain.getDomainOfValidity())) {
+ ImplementationHelper.propertyAlreadySet(AbstractReferenceSystem.class, "setDomainOfValidity", "domainOfValidity");
+ return;
+ }
+ scope = domain.getScope();
+ }
+ domains = Collections.singleton(new DefaultObjectDomain(scope, value));
+ }
+
+ /**
+ * Invoked by JAXB only at unmarshalling time.
+ */
+ private void setDomainScope(final InternationalString value) {
+ Extent area = null;
+ final ObjectDomain domain = CollectionsExt.first(domains);
+ if (domain != null) {
+ if (DefaultObjectDomain.isDefined(domain.getScope())) {
+ ImplementationHelper.propertyAlreadySet(AbstractReferenceSystem.class, "setScope", "scope");
+ return;
+ }
+ area = domain.getDomainOfValidity();
+ }
+ domains = Collections.singleton(new DefaultObjectDomain(value, area));
+ }
+
/**
* Invoked by JAXB for setting the remarks.
*
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractReferenceSystem.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractReferenceSystem.java
index cbfec78eb0..3c35b0cf24 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractReferenceSystem.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/AbstractReferenceSystem.java
@@ -17,22 +17,10 @@
package org.apache.sis.referencing;
import java.util.Map;
-import java.util.Objects;
-import jakarta.xml.bind.annotation.XmlElement;
import jakarta.xml.bind.annotation.XmlTransient;
-import jakarta.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import org.opengis.util.GenericName;
import org.opengis.util.InternationalString;
import org.opengis.referencing.ReferenceSystem;
-import org.opengis.metadata.extent.Extent;
-import org.apache.sis.util.Workaround;
-import org.apache.sis.util.ComparisonMode;
-import org.apache.sis.util.iso.Types;
-import org.apache.sis.xml.bind.metadata.EX_Extent;
-import org.apache.sis.metadata.internal.ImplementationHelper;
-
-import static org.apache.sis.util.Utilities.deepEquals;
-import static org.apache.sis.util.collection.Containers.property;
// Specific to the geoapi-3.1 and geoapi-4.0 branches:
import org.opengis.metadata.Identifier;
@@ -45,13 +33,8 @@ import org.opengis.metadata.Identifier;
* {@link org.apache.sis.referencing.crs.AbstractCRS} subclass.
*
* <p>This class inherits the {@linkplain #getName() name}, {@linkplain #getAlias() aliases},
- * {@linkplain #getIdentifiers() identifiers} and {@linkplain #getRemarks() remarks} from
- * the parent class, and adds the following information:</p>
- *
- * <ul>
- * <li>a {@linkplain #getDomainOfValidity() domain of validity}, the area for which the reference system is valid,</li>
- * <li>a {@linkplain #getScope() scope}, which describes the domain of usage or limitation of usage.
- * </ul>
+ * {@linkplain #getIdentifiers() identifiers}, {@linkplain #getDomains() domains}
+ * and {@linkplain #getRemarks() remarks} from the parent class.</p>
*
* <h2>Instantiation</h2>
* This class is conceptually <cite>abstract</cite>, even if it is technically possible to instantiate it.
@@ -73,36 +56,13 @@ public class AbstractReferenceSystem extends AbstractIdentifiedObject implements
/**
* Serial number for inter-operability with different versions.
*/
- private static final long serialVersionUID = 3337659819553899435L;
-
- /**
- * Area for which the (coordinate) reference system is valid.
- *
- * <p><b>Consider this field as final!</b>
- * This field is modified only at unmarshalling time by {@link #setDomainOfValidity(Extent)}</p>
- *
- * @see #getDomainOfValidity()
- */
- @SuppressWarnings("serial") // Most SIS implementations are serializable.
- private Extent domainOfValidity;
-
- /**
- * Description of domain of usage, or limitations of usage,
- * for which this (coordinate) reference system object is valid.
- *
- * <p><b>Consider this field as final!</b>
- * This field is modified only at unmarshalling time by {@link #setScope(InternationalString)}</p>
- *
- * @see #getScope()
- */
- @SuppressWarnings("serial") // Most SIS implementations are serializable.
- private InternationalString scope;
+ private static final long serialVersionUID = 7207447363999869238L;
/**
* Constructs a reference system from the given properties.
* The properties given in argument follow the same rules than for the
* {@linkplain AbstractIdentifiedObject#AbstractIdentifiedObject(Map) super-class constructor}.
- * Additionally, the following properties are understood by this constructor:
+ * The following table is a reminder of main (not all) properties:
*
* <table class="sis">
* <caption>Recognized properties (non exhaustive list)</caption>
@@ -110,36 +70,23 @@ public class AbstractReferenceSystem extends AbstractIdentifiedObject implements
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link String} or {@link InternationalString}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
- * <tr>
- * <th colspan="3" class="hsep">Defined in parent class (reminder)</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
@@ -150,8 +97,6 @@ public class AbstractReferenceSystem extends AbstractIdentifiedObject implements
*/
public AbstractReferenceSystem(final Map<String,?> properties) {
super(properties);
- domainOfValidity = property(properties, DOMAIN_OF_VALIDITY_KEY, Extent.class);
- scope = Types.toInternationalString(properties, SCOPE_KEY);
}
/**
@@ -165,8 +110,6 @@ public class AbstractReferenceSystem extends AbstractIdentifiedObject implements
*/
protected AbstractReferenceSystem(final ReferenceSystem object) {
super(object);
- domainOfValidity = object.getDomainOfValidity();
- scope = object.getScope();
}
/**
@@ -181,82 +124,6 @@ public class AbstractReferenceSystem extends AbstractIdentifiedObject implements
return ReferenceSystem.class;
}
- /**
- * Returns the region or timeframe in which this reference system is valid, or {@code null} if unspecified.
- *
- * @return area or region or timeframe in which this (coordinate) reference system is valid, or {@code null}.
- *
- * @see org.apache.sis.metadata.iso.extent.DefaultExtent
- */
- @Override
- @XmlElement(name = "domainOfValidity")
- // For an unknown reason, JAXB does not take the adapter declared in package-info for this particular property.
- @Workaround(library = "JDK", version = "1.8")
- @XmlJavaTypeAdapter(EX_Extent.class)
- public Extent getDomainOfValidity() {
- return domainOfValidity;
- }
-
- /**
- * Returns the domain or limitations of usage, or {@code null} if unspecified.
- *
- * @return description of domain of usage, or limitations of usage, for which this
- * (coordinate) reference system object is valid, or {@code null}.
- */
- @Override
- @XmlElement(name ="scope", required = true)
- public InternationalString getScope() {
- return scope;
- }
-
- /**
- * Compares this reference system with the specified object for equality.
- * If the {@code mode} argument value is {@link ComparisonMode#STRICT STRICT} or
- * {@link ComparisonMode#BY_CONTRACT BY_CONTRACT}, then all available properties are
- * compared including the {@linkplain #getDomainOfValidity() domain of validity} and
- * the {@linkplain #getScope() scope}.
- *
- * @param object the object to compare to {@code this}.
- * @param mode {@link ComparisonMode#STRICT STRICT} for performing a strict comparison, or
- * {@link ComparisonMode#IGNORE_METADATA IGNORE_METADATA} for comparing only
- * properties relevant to coordinate transformations.
- * @return {@code true} if both objects are equal.
- */
- @Override
- public boolean equals(final Object object, final ComparisonMode mode) {
- if (!super.equals(object, mode)) {
- return false;
- }
- switch (mode) {
- case STRICT: {
- final AbstractReferenceSystem that = (AbstractReferenceSystem) object;
- return Objects.equals(domainOfValidity, that.domainOfValidity) &&
- Objects.equals(scope, that.scope);
- }
- case BY_CONTRACT: {
- final ReferenceSystem that = (ReferenceSystem) object;
- return deepEquals(getDomainOfValidity(), that.getDomainOfValidity(), mode) &&
- deepEquals(getScope(), that.getScope(), mode);
- }
- default: {
- // Domain of validity and scope are metadata, so they can be ignored.
- return true;
- }
- }
- }
-
- /**
- * Invoked by {@code hashCode()} for computing the hash code when first needed.
- * See {@link org.apache.sis.referencing.AbstractIdentifiedObject#computeHashCode()}
- * for more information.
- *
- * @return the hash code value. This value may change in any future Apache SIS version.
- */
- @Override
- protected long computeHashCode() {
- return super.computeHashCode() + Objects.hash(domainOfValidity, scope);
- }
-
@@ -278,30 +145,4 @@ public class AbstractReferenceSystem extends AbstractIdentifiedObject implements
*/
AbstractReferenceSystem() {
}
-
- /**
- * Invoked by JAXB only at unmarshalling time.
- *
- * @see #getDomainOfValidity()
- */
- private void setDomainOfValidity(final Extent value) {
- if (domainOfValidity == null) {
- domainOfValidity = value;
- } else {
- ImplementationHelper.propertyAlreadySet(AbstractReferenceSystem.class, "setDomainOfValidity", "domainOfValidity");
- }
- }
-
- /**
- * Invoked by JAXB only at unmarshalling time.
- *
- * @see #getScope()
- */
- private void setScope(final InternationalString value) {
- if (scope == null) {
- scope = value;
- } else {
- ImplementationHelper.propertyAlreadySet(AbstractReferenceSystem.class, "setScope", "scope");
- }
- }
}
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/CRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/CRS.java
index 1aafd4c2b7..e872936e19 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/CRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/CRS.java
@@ -88,6 +88,7 @@ import org.apache.sis.util.logging.Logging;
// Specific to the geoapi-3.1 and geoapi-4.0 branches:
import org.opengis.geometry.Geometry;
+import org.opengis.referencing.ObjectDomain;
import org.opengis.metadata.extent.BoundingPolygon;
import org.opengis.metadata.extent.GeographicExtent;
@@ -774,12 +775,9 @@ public final class CRS extends Static {
if (operation == null) {
return null;
}
- GeographicBoundingBox bbox = Extents.getGeographicBoundingBox(operation.getDomainOfValidity());
- if (bbox == null) {
- bbox = Extents.intersection(getGeographicBoundingBox(operation.getSourceCRS()),
- getGeographicBoundingBox(operation.getTargetCRS()));
- }
- return bbox;
+ return Extents.getGeographicBoundingBox(operation.getDomains()).orElseGet(
+ () -> Extents.intersection(getGeographicBoundingBox(operation.getSourceCRS()),
+ getGeographicBoundingBox(operation.getTargetCRS())));
}
/**
@@ -799,7 +797,7 @@ public final class CRS extends Static {
*/
@OptionalCandidate
public static GeographicBoundingBox getGeographicBoundingBox(final CoordinateReferenceSystem crs) {
- return (crs != null) ? Extents.getGeographicBoundingBox(crs.getDomainOfValidity()) : null;
+ return (crs != null) ? Extents.getGeographicBoundingBox(crs.getDomains()).orElse(null) : null;
}
/**
@@ -830,22 +828,24 @@ public final class CRS extends Static {
Envelope envelope = null;
GeneralEnvelope merged = null;
if (crs != null) {
- final Extent domainOfValidity = crs.getDomainOfValidity();
- if (domainOfValidity != null) {
- for (final GeographicExtent extent : domainOfValidity.getGeographicElements()) {
- if (extent instanceof BoundingPolygon && !Boolean.FALSE.equals(extent.getInclusion())) {
- for (final Geometry geometry : ((BoundingPolygon) extent).getPolygons()) {
- final Envelope candidate = geometry.getEnvelope();
- if (candidate != null) {
- final CoordinateReferenceSystem sourceCRS = candidate.getCoordinateReferenceSystem();
- if (sourceCRS == null || Utilities.equalsIgnoreMetadata(sourceCRS, crs)) {
- if (envelope == null) {
- envelope = candidate;
- } else {
- if (merged == null) {
- envelope = merged = new GeneralEnvelope(envelope);
+ for (final ObjectDomain domain : crs.getDomains()) {
+ final Extent domainOfValidity = domain.getDomainOfValidity();
+ if (domainOfValidity != null) {
+ for (final GeographicExtent extent : domainOfValidity.getGeographicElements()) {
+ if (extent instanceof BoundingPolygon && !Boolean.FALSE.equals(extent.getInclusion())) {
+ for (final Geometry geometry : ((BoundingPolygon) extent).getPolygons()) {
+ final Envelope candidate = geometry.getEnvelope();
+ if (candidate != null) {
+ final CoordinateReferenceSystem sourceCRS = candidate.getCoordinateReferenceSystem();
+ if (sourceCRS == null || Utilities.equalsIgnoreMetadata(sourceCRS, crs)) {
+ if (envelope == null) {
+ envelope = candidate;
+ } else {
+ if (merged == null) {
+ envelope = merged = new GeneralEnvelope(envelope);
+ }
+ merged.add(envelope);
}
- merged.add(envelope);
}
}
}
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/DefaultObjectDomain.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/DefaultObjectDomain.java
new file mode 100644
index 0000000000..07ad21a943
--- /dev/null
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/DefaultObjectDomain.java
@@ -0,0 +1,221 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sis.referencing;
+
+import java.util.Objects;
+import java.io.Serializable;
+import org.opengis.metadata.extent.Extent;
+import org.opengis.util.InternationalString;
+import org.apache.sis.util.ComparisonMode;
+import org.apache.sis.util.LenientComparable;
+import org.apache.sis.util.Utilities;
+import org.apache.sis.util.resources.Vocabulary;
+import org.apache.sis.referencing.util.WKTKeywords;
+import org.apache.sis.io.wkt.FormattableObject;
+import org.apache.sis.io.wkt.Formatter;
+import org.apache.sis.metadata.iso.extent.DefaultExtent;
+
+// Specific to the geoapi-3.1 and geoapi-4.0 branches:
+import org.opengis.referencing.ObjectDomain;
+
+
+/**
+ * Default implementation of scope and domain of validity of a CRS-related object.
+ *
+ * @author Martin Desruisseaux (Geomatys)
+ * @version 1.4
+ * @since 1.4
+ */
+public class DefaultObjectDomain extends FormattableObject implements ObjectDomain, LenientComparable, Serializable {
+ /**
+ * Serial number for inter-operability with different versions.
+ */
+ private static final long serialVersionUID = 5797839090924498526L;
+
+ /**
+ * The text used by default when the scope was not specified.
+ * The <i>"not known"</i> text is standardized by ISO 19111.
+ * The text may be localized.
+ *
+ * @see #isDefined(InternationalString)
+ */
+ public static final InternationalString UNKNOWN_SCOPE = Vocabulary.formatInternational(Vocabulary.Keys.NotKnown);
+
+ /**
+ * The extent used by default when the domain of validity was not specified.
+ *
+ * @see #isDefined(Extent)
+ */
+ public static final Extent UNKNOWN_EXTENT;
+ static {
+ final var domainOfValidity = new DefaultExtent(UNKNOWN_SCOPE, null, null, null);
+ domainOfValidity.transitionTo(DefaultExtent.State.FINAL);
+ UNKNOWN_EXTENT = domainOfValidity;
+ }
+
+ /**
+ * Description of domain of usage, or limitations of usage, for which the object is valid.
+ *
+ * @see #getScope()
+ */
+ @SuppressWarnings("serial") // Most SIS implementations are serializable.
+ private final InternationalString scope;
+
+ /**
+ * Area for which the object is valid.
+ *
+ * @see #getDomainOfValidity()
+ */
+ @SuppressWarnings("serial") // Most SIS implementations are serializable.
+ private final Extent domainOfValidity;
+
+ /**
+ * Creates a new domain with the given scope and extent.
+ * If any value is {@code null}, the text will be set to "not known" (potentially localized).
+ * The <i>"not known"</i> text is standardized by ISO 19111 for the scope.
+ *
+ * @param scope description of domain of usage, or limitations of usage.
+ * @param domainOfValidity area for which the object is valid.
+ */
+ public DefaultObjectDomain(InternationalString scope, Extent domainOfValidity) {
+ if (scope == null) {
+ scope = UNKNOWN_SCOPE;
+ }
+ if (domainOfValidity == null) {
+ domainOfValidity = UNKNOWN_EXTENT;
+ }
+ this.scope = scope;
+ this.domainOfValidity = domainOfValidity;
+ }
+
+ /**
+ * Returns a description of usage, or limitations of usage, for which this object is valid.
+ *
+ * @return the domain of usage.
+ */
+ @Override
+ public InternationalString getScope() {
+ return scope;
+ }
+
+ /**
+ * Returns the spatial and temporal extent in which this object is valid.
+ *
+ * @return the area or time frame of usage.
+ */
+ @Override
+ public Extent getDomainOfValidity() {
+ return domainOfValidity;
+ }
+
+ /**
+ * Returns {@code true} if the given scope is neither null or not known.
+ *
+ * @param scope the scope to test.
+ * @return {@code true} if the given scope is not null and not {@link #UNKNOWN_SCOPE}.
+ */
+ public static boolean isDefined(final InternationalString scope) {
+ return (scope != null) && (scope != UNKNOWN_SCOPE);
+ }
+
+ /**
+ * Returns {@code true} if the given extent is neither null or not known.
+ *
+ * @param domainOfValidity the extent to test.
+ * @return {@code true} if the given extent is not null and not {@link #UNKNOWN_EXTENT}.
+ */
+ public static boolean isDefined(final Extent domainOfValidity) {
+ return (domainOfValidity != null) && (domainOfValidity != UNKNOWN_EXTENT);
+ }
+
+ /**
+ * Compares the specified object with this object for equality.
+ * This method is implemented as below (omitting assertions):
+ *
+ * {@snippet lang="java" :
+ * return equals(other, ComparisonMode.STRICT);
+ * }
+ *
+ * Subclasses shall override {@link #equals(Object, ComparisonMode)} instead of this method.
+ *
+ * @param object the other object (may be {@code null}).
+ * @return {@code true} if both objects are equal.
+ */
+ @Override
+ public final boolean equals(final Object object) {
+ final boolean eq = equals(object, ComparisonMode.STRICT);
+ // If objects are equal, then they must have the same hash code value.
+ assert !eq || hashCode() == object.hashCode() : this;
+ return eq;
+ }
+
+ /**
+ * Compares this object system with the specified object for equality.
+ *
+ * @param object the object to compare to {@code this}.
+ * @param mode {@link ComparisonMode#STRICT STRICT} or
+ * {@link ComparisonMode#IGNORE_METADATA IGNORE_METADATA}.
+ * @return {@code true} if both objects are equal.
+ */
+ @Override
+ public boolean equals(final Object object, final ComparisonMode mode) {
+ if (mode == ComparisonMode.STRICT) {
+ if (object != null && object.getClass() == getClass()) {
+ final var that = (DefaultObjectDomain) object;
+ return Objects.equals(scope, that.scope) &&
+ Objects.equals(domainOfValidity, that.domainOfValidity);
+ }
+ } else {
+ if (object instanceof ObjectDomain) {
+ final var that = (ObjectDomain) object;
+ return Utilities.deepEquals(getScope(), that.getScope(), mode) &&
+ Utilities.deepEquals(getDomainOfValidity(), that.getDomainOfValidity(), mode);
+ }
+ }
+ return false;
+ }
+
+ /**
+ * Returns a hash code value for this domain.
+ *
+ * @return a hash code value.
+ */
+ @Override
+ public int hashCode() {
+ return Objects.hash(scope, domainOfValidity);
+ }
+
+ /**
+ * Formats the inner part of the <cite>Well Known Text</cite> (WKT) representation for this object.
+ * The default implementation writes the following elements:
+ *
+ * <ul>
+ * <li>The object {@linkplain #getScope() scope}.</li>
+ * <li>The geographic description of the {@linkplain #getDomainOfValidity() domain of validity}.</li>
+ * <li>The geographic bounding box of the domain of validity.</li>
+ * </ul>
+ *
+ * @param formatter the formatter where to format the inner content of this WKT element.
+ * @return the {@linkplain org.apache.sis.io.wkt.KeywordCase#CAMEL_CASE CamelCase} keyword
+ * for the WKT element, or {@code null} if unknown.
+ */
+ @Override
+ protected String formatTo(final Formatter formatter) {
+ formatter.append(scope, domainOfValidity);
+ return WKTKeywords.Usage;
+ }
+}
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/IdentifiedObjects.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/IdentifiedObjects.java
index f07448752c..d4b50835d8 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/IdentifiedObjects.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/IdentifiedObjects.java
@@ -50,6 +50,9 @@ import org.apache.sis.referencing.factory.NoSuchAuthorityFactoryException;
import static org.apache.sis.util.internal.CollectionsExt.nonNull;
+// Specific to the geoapi-3.1 and geoapi-4.0 branches:
+import org.opengis.referencing.ObjectDomain;
+
/**
* Utility methods working on arbitrary implementations of the {@link IdentifiedObject} interface.
@@ -84,12 +87,14 @@ public final class IdentifiedObjects extends Static {
* <td>{@link IdentifiedObject#getAlias()}</td></tr>
* <tr><td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link IdentifiedObject#getIdentifiers()}</td></tr>
+ * <tr><td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link IdentifiedObject#getDomains()}</td></tr>
* <tr><td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link IdentifiedObject#getRemarks()}</td></tr>
- * <tr><td>{@value org.opengis.referencing.operation.CoordinateOperation#SCOPE_KEY}</td>
- * <td>{@link CoordinateOperation#getScope()} (also in datum and reference systems)</td></tr>
- * <tr><td>{@value org.opengis.referencing.operation.CoordinateOperation#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link CoordinateOperation#getDomainOfValidity()} (also in datum and reference systems)</td></tr>
+ * <tr><td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
+ * <td>{@link ObjectDomain#getScope()}</td></tr>
+ * <tr><td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
+ * <td>{@link ObjectDomain#getDomainOfValidity()}</td></tr>
* <tr><td>{@value org.opengis.referencing.operation.CoordinateOperation#OPERATION_VERSION_KEY}</td>
* <td>{@link CoordinateOperation#getOperationVersion()}</td></tr>
* <tr><td>{@value org.opengis.referencing.operation.CoordinateOperation#COORDINATE_OPERATION_ACCURACY_KEY}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/NameIterator.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/NameIterator.java
index 8aa4e97eb1..082ce983fb 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/NameIterator.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/NameIterator.java
@@ -21,6 +21,7 @@ import java.util.Collection;
import org.opengis.util.GenericName;
import org.opengis.referencing.IdentifiedObject;
import org.apache.sis.xml.bind.Context;
+import org.apache.sis.util.resources.Errors;
import org.apache.sis.metadata.internal.NameMeaning;
import org.apache.sis.referencing.util.NilReferencingObject;
@@ -40,7 +41,7 @@ import org.opengis.metadata.Identifier;
* <p>This class also opportunistically provide helper methods for {@link AbstractIdentifiedObject} marshalling.</p>
*
* @author Martin Desruisseaux (Geomatys)
- * @version 0.7
+ * @version 1.4
* @since 0.4
*/
final class NameIterator implements Iterator<Identifier> {
@@ -120,8 +121,9 @@ final class NameIterator implements Iterator<Identifier> {
}
/**
- * Implementation of {@link AbstractIdentifiedObject#getID()}, provided here for reducing the amount of code
- * to load in the common case where XML support is not needed.
+ * Implementation of XML marshalling of GML object identifier.
+ * This is provided here for reducing the amount of code to load
+ * in the common case where XML support is not needed.
*
* <p>The current implementation searches for the first identifier, regardless its authority.
* If no identifier is found, then the name and aliases are used.
@@ -138,16 +140,18 @@ final class NameIterator implements Iterator<Identifier> {
* Consecutive invocations of this method do not need to return the same value,
* since it may depends on the marshalling context.</p>
*
- * @param context the (un)marshalling context.
* @param object the object for which to get a {@code gml:id}.
* @param name the identified object name, or {@code null} if none.
* @param alias the identified object aliases, or {@code null} if none.
* @param identifiers the identifiers, or {@code null} if none.
* @return proposed value for {@code gml:id} attribute, or {@code null} if none.
+ *
+ * @see AbstractIdentifiedObject#getID()
*/
- static String getID(final Context context, final IdentifiedObject object, final Identifier name,
+ static String getID(final IdentifiedObject object, final Identifier name,
final Collection<? extends GenericName> alias, final Collection<? extends Identifier> identifiers)
{
+ final Context context = Context.current();
String candidate = Context.getObjectID(context, object);
if (candidate == null) {
final StringBuilder id = new StringBuilder();
@@ -201,4 +205,22 @@ final class NameIterator implements Iterator<Identifier> {
}
return candidate;
}
+
+ /**
+ * Implementation of XML unmarshalling of GML object identifier.
+ * This is provided here for reducing the amount of code to load
+ * in the common case where XML support is not needed.
+ *
+ * @param object the object for which to set a {@code gml:id}.
+ * @param id the identifier to set.
+ *
+ * @see AbstractIdentifiedObject#setID(String)
+ */
+ static void setID(final IdentifiedObject object, final String id) {
+ final Context context = Context.current();
+ if (!Context.setObjectForID(context, object, id)) {
+ Context.warningOccured(context, AbstractIdentifiedObject.class, "setID",
+ Errors.class, Errors.Keys.DuplicatedIdentifier_1, id);
+ }
+ }
}
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/Properties.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/Properties.java
index b45707b85c..815c29047c 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/Properties.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/Properties.java
@@ -19,6 +19,7 @@ package org.apache.sis.referencing;
import java.util.Map;
import java.util.HashMap;
import java.util.Collection;
+import java.util.function.IntFunction;
import java.io.Serializable;
import org.opengis.util.GenericName;
import org.opengis.referencing.ReferenceSystem;
@@ -34,6 +35,7 @@ import org.apache.sis.referencing.util.CoordinateOperations;
// Specific to the geoapi-4.0 branch:
import org.opengis.metadata.Identifier;
+import org.opengis.referencing.ObjectDomain;
/**
@@ -45,7 +47,7 @@ import org.opengis.metadata.Identifier;
* underlying {@code IdentifiedObject} instance is itself serializable, immutable or thread-safe.</p>
*
* @author Martin Desruisseaux (IRD, Geomatys)
- * @version 1.1
+ * @version 1.4
* @since 0.4
*/
final class Properties extends AbstractMap<String,Object> implements Serializable {
@@ -62,14 +64,15 @@ final class Properties extends AbstractMap<String,Object> implements Serializabl
/*[ 0]*/ IdentifiedObject .NAME_KEY,
/*[ 1]*/ IdentifiedObject .IDENTIFIERS_KEY,
/*[ 2]*/ IdentifiedObject .ALIAS_KEY,
- /*[ 3]*/ IdentifiedObject .REMARKS_KEY,
- /*[ 4]*/ CoordinateOperation .SCOPE_KEY, // same in Datum and ReferenceSystem
- /*[ 5]*/ CoordinateOperation .DOMAIN_OF_VALIDITY_KEY, // same in Datum and ReferenceSystem
- /*[ 6]*/ CoordinateOperation .OPERATION_VERSION_KEY,
- /*[ 7]*/ CoordinateOperation .COORDINATE_OPERATION_ACCURACY_KEY,
- /*[ 8]*/ OperationMethod .FORMULA_KEY,
- /*[ 9]*/ CoordinateOperations .PARAMETERS_KEY,
- /*[10]*/ AbstractIdentifiedObject.DEPRECATED_KEY
+ /*[ 3]*/ IdentifiedObject .DOMAINS_KEY,
+ /*[ 4]*/ IdentifiedObject .REMARKS_KEY,
+ /*[ 5]*/ CoordinateOperation .SCOPE_KEY, // same in Datum and ReferenceSystem
+ /*[ 6]*/ CoordinateOperation .DOMAIN_OF_VALIDITY_KEY, // same in Datum and ReferenceSystem
+ /*[ 7]*/ CoordinateOperation .OPERATION_VERSION_KEY,
+ /*[ 8]*/ CoordinateOperation .COORDINATE_OPERATION_ACCURACY_KEY,
+ /*[ 9]*/ OperationMethod .FORMULA_KEY,
+ /*[10]*/ CoordinateOperations .PARAMETERS_KEY,
+ /*[11]*/ AbstractIdentifiedObject.DEPRECATED_KEY
/*
* The current implementation does not look for minimum and maximum values in ParameterDescriptor
@@ -126,33 +129,12 @@ final class Properties extends AbstractMap<String,Object> implements Serializabl
final Object getAt(final int key) {
if ((excludeMask & (1 << key)) == 0) {
switch (key) {
- case 0: { // NAME_KEY
- return object.getName();
- }
- case 1: { // IDENTIFIERS_KEY
- final Collection<Identifier> c = object.getIdentifiers();
- if (c != null) {
- final int size = c.size();
- if (size != 0) {
- return c.toArray(new Identifier[size]);
- }
- }
- break;
- }
- case 2: { // ALIAS_KEY
- final Collection<GenericName> c = object.getAlias();
- if (c != null) {
- final int size = c.size();
- if (size != 0) {
- return c.toArray(new GenericName[size]);
- }
- }
- break;
- }
- case 3: { // REMARKS_KEY
- return object.getRemarks();
- }
- case 4: { // SCOPE_KEY
+ case 0: return object.getName(); // NAME_KEY
+ case 1: return toArray(object.getIdentifiers(), Identifier[]::new); // IDENTIFIERS_KEY
+ case 2: return toArray(object.getAlias(), GenericName[]::new); // ALIAS_KEY
+ case 3: return toArray(object.getDomains(), ObjectDomain[]::new); // DOMAINS_KEY
+ case 4: return object.getRemarks(); // REMARKS_KEY
+ case 5: { // SCOPE_KEY
if (object instanceof ReferenceSystem) {
return ((ReferenceSystem) object).getScope();
} else if (object instanceof Datum) {
@@ -162,7 +144,7 @@ final class Properties extends AbstractMap<String,Object> implements Serializabl
}
break;
}
- case 5: { // DOMAIN_OF_VALIDITY_KEY
+ case 6: { // DOMAIN_OF_VALIDITY_KEY
if (object instanceof ReferenceSystem) {
return ((ReferenceSystem) object).getDomainOfValidity();
} else if (object instanceof Datum) {
@@ -172,37 +154,31 @@ final class Properties extends AbstractMap<String,Object> implements Serializabl
}
break;
}
- case 6: { // OPERATION_VERSION_KEY
+ case 7: { // OPERATION_VERSION_KEY
if (object instanceof CoordinateOperation) {
return ((CoordinateOperation) object).getOperationVersion();
}
break;
}
- case 7: { // COORDINATE_OPERATION_ACCURACY_KEY
+ case 8: { // COORDINATE_OPERATION_ACCURACY_KEY
if (object instanceof CoordinateOperation) {
- final Collection<PositionalAccuracy> c = ((CoordinateOperation) object).getCoordinateOperationAccuracy();
- if (c != null) {
- final int size = c.size();
- if (size != 0) {
- return c.toArray(new PositionalAccuracy[size]);
- }
- }
+ return toArray(((CoordinateOperation) object).getCoordinateOperationAccuracy(), PositionalAccuracy[]::new);
}
break;
}
- case 8: { // FORMULA_KEY
+ case 9: { // FORMULA_KEY
if (object instanceof OperationMethod) {
return ((OperationMethod) object).getFormula();
}
break;
}
- case 9: { // PARAMETERS_KEY
+ case 10: { // PARAMETERS_KEY
if (object instanceof SingleOperation) {
return ((SingleOperation) object).getParameterValues();
}
break;
}
- case 10: { // DEPRECATED_KEY
+ case 11: { // DEPRECATED_KEY
if (object instanceof Deprecable) {
return ((Deprecable) object).isDeprecated();
}
@@ -214,6 +190,19 @@ final class Properties extends AbstractMap<String,Object> implements Serializabl
return null;
}
+ /**
+ * Returns the collection content as an array if the collection is non-null and non-empty.
+ * Otherwise returns {@code null}.
+ *
+ * @param <E> type of elements in the collection.
+ * @param c the collection, or {@code null}.
+ * @param generator function to invoke for creating an initially empty array.
+ * @return array of collection elements, or {@code null}.
+ */
+ private static <E> E[] toArray(final Collection<E> c, final IntFunction<E[]> generator) {
+ return (c == null || c.isEmpty()) ? null : c.toArray(generator);
+ }
+
/**
* Returns {@code false} if this map contains at least one element, or {@code true} otherwise.
*/
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/AbstractCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/AbstractCRS.java
index 41cbb01837..1e9475fd07 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/AbstractCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/AbstractCRS.java
@@ -90,10 +90,7 @@ import org.opengis.metadata.Identifier;
*
* @since 0.4
*/
-@XmlType(name = "AbstractCRSType", propOrder = {
- "domainOfValidity",
- "scope"
-})
+@XmlType(name = "AbstractCRSType")
@XmlRootElement(name = "AbstractCRS")
@XmlSeeAlso({
AbstractDerivedCRS.class,
@@ -142,37 +139,27 @@ public class AbstractCRS extends AbstractReferenceSystem implements CoordinateRe
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultCompoundCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultCompoundCRS.java
index 2d22dd2642..12aebff9fe 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultCompoundCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultCompoundCRS.java
@@ -154,37 +154,27 @@ public class DefaultCompoundCRS extends AbstractCRS implements CompoundCRS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultDerivedCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultDerivedCRS.java
index 98aeb11bdf..02fbcdb736 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultDerivedCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultDerivedCRS.java
@@ -124,37 +124,27 @@ public class DefaultDerivedCRS extends AbstractDerivedCRS<Conversion> implements
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* The supplied {@code conversion} argument shall <strong>not</strong> includes the operation steps
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultEngineeringCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultEngineeringCRS.java
index 32f063f5a9..9894d4e09e 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultEngineeringCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultEngineeringCRS.java
@@ -109,37 +109,27 @@ public class DefaultEngineeringCRS extends AbstractCRS implements EngineeringCRS
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeocentricCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeocentricCRS.java
index f95684cb56..91e14a8ffa 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeocentricCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeocentricCRS.java
@@ -105,37 +105,27 @@ public class DefaultGeocentricCRS extends DefaultGeodeticCRS implements Geocentr
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeographicCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeographicCRS.java
index 66ec9c0bf6..025930b1bc 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeographicCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultGeographicCRS.java
@@ -127,32 +127,23 @@ public class DefaultGeographicCRS extends DefaultGeodeticCRS implements Geograph
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultImageCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultImageCRS.java
index 4de3cd0d52..302b62acc3 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultImageCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultImageCRS.java
@@ -94,37 +94,27 @@ public class DefaultImageCRS extends AbstractCRS implements ImageCRS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultParametricCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultParametricCRS.java
index 4f30502261..a9ae91111b 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultParametricCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultParametricCRS.java
@@ -94,37 +94,27 @@ public class DefaultParametricCRS extends AbstractCRS implements ParametricCRS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java
index 9aa08d3b0a..225d04e76e 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultProjectedCRS.java
@@ -89,37 +89,27 @@ public class DefaultProjectedCRS extends AbstractDerivedCRS<Projection> implemen
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* The supplied {@code conversion} argument shall <strong>not</strong> includes the operation steps
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultTemporalCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultTemporalCRS.java
index 19129e31a4..e8de4c658e 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultTemporalCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultTemporalCRS.java
@@ -124,37 +124,27 @@ public class DefaultTemporalCRS extends AbstractCRS implements TemporalCRS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultVerticalCRS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultVerticalCRS.java
index e59271a69a..f6c43ee8f1 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultVerticalCRS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/crs/DefaultVerticalCRS.java
@@ -92,37 +92,27 @@ public class DefaultVerticalCRS extends AbstractCRS implements VerticalCRS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the coordinate reference system.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AbstractCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AbstractCS.java
index 7bd48643db..81d87e70ad 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AbstractCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AbstractCS.java
@@ -144,23 +144,19 @@ public class AbstractCS extends AbstractIdentifiedObject implements CoordinateSy
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AxesConvention.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AxesConvention.java
index 64399a6750..ffd6ffb0e5 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AxesConvention.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/AxesConvention.java
@@ -43,32 +43,28 @@ import org.apache.sis.measure.Units;
* <th>{@link #DISPLAY_ORIENTED Display<br>oriented}</th>
* <th>{@linkplain #RIGHT_HANDED Right<br>handed}</th>
* <th>{@linkplain #POSITIVE_RANGE Positive<br>range}</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>Axis order</td>
* <td>(<var>longitude</var>, <var>latitude</var>)</td>
* <td style="text-align:center">✔</td>
* <td style="text-align:center">✔</td>
* <td style="text-align:center">✔</td>
* <td></td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>Axis direction</td>
* <td>({@linkplain AxisDirection#EAST east}, {@linkplain AxisDirection#NORTH north})</td>
* <td style="text-align:center">✔</td>
* <td style="text-align:center">✔</td>
* <td></td>
* <td></td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>Unit of measurement</td>
* <td>Angular degrees & metres</td>
* <td style="text-align:center">✔</td>
* <td></td>
* <td></td>
* <td></td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>Range of values</td>
* <td>[0 … 360]° of longitude</td>
* <td></td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultAffineCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultAffineCS.java
index 77a93f4bb3..b6f2e9b7e2 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultAffineCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultAffineCS.java
@@ -82,23 +82,19 @@ public class DefaultAffineCS extends AbstractCS implements AffineCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCartesianCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCartesianCS.java
index 65f15646c1..ee72d04efe 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCartesianCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCartesianCS.java
@@ -91,23 +91,19 @@ public class DefaultCartesianCS extends DefaultAffineCS implements CartesianCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCompoundCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCompoundCS.java
index 113132b801..467add2046 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCompoundCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCompoundCS.java
@@ -79,23 +79,19 @@ public class DefaultCompoundCS extends AbstractCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCoordinateSystemAxis.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCoordinateSystemAxis.java
index 9c32446cb7..957dc78758 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCoordinateSystemAxis.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCoordinateSystemAxis.java
@@ -240,41 +240,33 @@ public class DefaultCoordinateSystemAxis extends AbstractIdentifiedObject implem
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value #MINIMUM_VALUE_KEY}</td>
* <td>{@link Number}</td>
* <td>{@link #getMinimumValue()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value #MAXIMUM_VALUE_KEY}</td>
* <td>{@link Number}</td>
* <td>{@link #getMaximumValue()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value #RANGE_MEANING_KEY}</td>
* <td>{@link RangeMeaning}</td>
* <td>{@link #getRangeMeaning()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <th colspan="3" class="hsep">Defined in parent class (reminder)</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCylindricalCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCylindricalCS.java
index e44be7edba..a4ed713fc5 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCylindricalCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultCylindricalCS.java
@@ -84,23 +84,19 @@ public class DefaultCylindricalCS extends AbstractCS implements CylindricalCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultEllipsoidalCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultEllipsoidalCS.java
index 3510258c1e..ee3ab487af 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultEllipsoidalCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultEllipsoidalCS.java
@@ -84,23 +84,19 @@ public class DefaultEllipsoidalCS extends AbstractCS implements EllipsoidalCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultLinearCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultLinearCS.java
index bd51237977..e5891f0245 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultLinearCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultLinearCS.java
@@ -81,23 +81,19 @@ public class DefaultLinearCS extends AbstractCS implements LinearCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultParametricCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultParametricCS.java
index 43ee0e03c2..63fbcdcaf1 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultParametricCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultParametricCS.java
@@ -82,23 +82,19 @@ public class DefaultParametricCS extends AbstractCS implements ParametricCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultPolarCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultPolarCS.java
index 586d7c26c9..ee44bc1c2b 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultPolarCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultPolarCS.java
@@ -84,23 +84,19 @@ public class DefaultPolarCS extends AbstractCS implements PolarCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultSphericalCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultSphericalCS.java
index 0201aea8f6..1dae32f4d9 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultSphericalCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultSphericalCS.java
@@ -88,23 +88,19 @@ public class DefaultSphericalCS extends AbstractCS implements SphericalCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultTimeCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultTimeCS.java
index 2ba61c986e..ce610c83db 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultTimeCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultTimeCS.java
@@ -84,23 +84,19 @@ public class DefaultTimeCS extends AbstractCS implements TimeCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultUserDefinedCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultUserDefinedCS.java
index 597bbdccd9..865c2f0a2a 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultUserDefinedCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultUserDefinedCS.java
@@ -75,23 +75,19 @@ public class DefaultUserDefinedCS extends AbstractCS implements UserDefinedCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultVerticalCS.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultVerticalCS.java
index 49d377c4d6..daf102bb97 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultVerticalCS.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/cs/DefaultVerticalCS.java
@@ -95,23 +95,19 @@ public class DefaultVerticalCS extends AbstractCS implements VerticalCS {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/AbstractDatum.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/AbstractDatum.java
index 711f1f31f2..42ca05dd72 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/AbstractDatum.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/AbstractDatum.java
@@ -26,7 +26,6 @@ import jakarta.xml.bind.annotation.XmlRootElement;
import jakarta.xml.bind.annotation.XmlSeeAlso;
import org.opengis.util.GenericName;
import org.opengis.util.InternationalString;
-import org.opengis.metadata.extent.Extent;
import org.opengis.metadata.citation.Citation;
import org.opengis.referencing.datum.Datum;
import org.apache.sis.referencing.AbstractIdentifiedObject;
@@ -74,8 +73,6 @@ import org.opengis.metadata.Identifier;
* @since 0.4
*/
@XmlType(name = "AbstractDatumType", propOrder = {
- "domainOfValidity",
- "scope",
"anchorPoint",
"realizationEpoch"
})
@@ -92,7 +89,7 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
/**
* Serial number for inter-operability with different versions.
*/
- private static final long serialVersionUID = -4894180465652474930L;
+ private static final long serialVersionUID = -729506171131910731L;
/**
* Description, possibly including coordinates, of the point or points used to anchor the datum
@@ -116,28 +113,6 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
*/
private long realizationEpoch;
- /**
- * Area or region in which this datum object is valid.
- *
- * <p><b>Consider this field as final!</b>
- * This field is modified only at unmarshalling time by {@link #setDomainOfValidity(Extent)}</p>
- *
- * @see #getDomainOfValidity()
- */
- @SuppressWarnings("serial") // Most SIS implementations are serializable.
- private Extent domainOfValidity;
-
- /**
- * Description of domain of usage, or limitations of usage, for which this datum object is valid.
- *
- * <p><b>Consider this field as final!</b>
- * This field is modified only at unmarshalling time by {@link #setScope(InternationalString)}</p>
- *
- * @see #getScope()
- */
- @SuppressWarnings("serial") // Most SIS implementations are serializable.
- private InternationalString scope;
-
/**
* Creates a datum from the given properties.
* The properties given in argument follow the same rules than for the
@@ -150,46 +125,33 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link Date}</td>
* <td>{@link #getRealizationEpoch()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#SCOPE_KEY}</td>
- * <td>{@link InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <th colspan="3" class="hsep">Defined in parent class (reminder)</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
@@ -201,9 +163,7 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
public AbstractDatum(final Map<String,?> properties) {
super(properties);
realizationEpoch = ImplementationHelper.toMilliseconds(property(properties, REALIZATION_EPOCH_KEY, Date.class));
- domainOfValidity = property(properties, DOMAIN_OF_VALIDITY_KEY, Extent.class);
anchorDefinition = Types.toInternationalString(properties, ANCHOR_POINT_KEY);
- scope = Types.toInternationalString(properties, SCOPE_KEY);
}
/**
@@ -218,8 +178,6 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
protected AbstractDatum(final Datum datum) {
super(datum);
realizationEpoch = ImplementationHelper.toMilliseconds(datum.getRealizationEpoch());
- domainOfValidity = datum.getDomainOfValidity();
- scope = datum.getScope();
anchorDefinition = datum.getAnchorPoint();
}
@@ -308,30 +266,6 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
return ImplementationHelper.toDate(realizationEpoch);
}
- /**
- * Returns the region or timeframe in which this datum is valid, or {@code null} if unspecified.
- *
- * @return area or region or timeframe in which this datum is valid, or {@code null}.
- *
- * @see org.apache.sis.metadata.iso.extent.DefaultExtent
- */
- @Override
- @XmlElement(name = "domainOfValidity")
- public Extent getDomainOfValidity() {
- return domainOfValidity;
- }
-
- /**
- * Returns the domain or limitations of usage, or {@code null} if unspecified.
- *
- * @return description of domain of usage, or limitations of usage, for which this datum object is valid.
- */
- @Override
- @XmlElement(name = "scope", required = true)
- public InternationalString getScope() {
- return scope;
- }
-
/**
* Returns {@code true} if either the {@linkplain #getName() primary name} or at least
* one {@linkplain #getAlias() alias} matches the given string according heuristic rules.
@@ -390,7 +324,7 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
* If the {@code mode} argument value is {@link ComparisonMode#STRICT STRICT} or
* {@link ComparisonMode#BY_CONTRACT BY_CONTRACT}, then all available properties are compared including the
* {@linkplain #getAnchorPoint() anchor point}, {@linkplain #getRealizationEpoch() realization epoch},
- * {@linkplain #getDomainOfValidity() domain of validity} and the {@linkplain #getScope() scope}.
+ * and the {@linkplain #getDomains() domains}.
*
* @param object the object to compare to {@code this}.
* @param mode {@link ComparisonMode#STRICT STRICT} for performing a strict comparison, or
@@ -407,16 +341,12 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
case STRICT: {
final AbstractDatum that = (AbstractDatum) object;
return this.realizationEpoch == that.realizationEpoch &&
- Objects.equals(this.domainOfValidity, that.domainOfValidity) &&
- Objects.equals(this.anchorDefinition, that.anchorDefinition) &&
- Objects.equals(this.scope, that.scope);
+ Objects.equals(this.anchorDefinition, that.anchorDefinition);
}
case BY_CONTRACT: {
final Datum that = (Datum) object;
return deepEquals(getRealizationEpoch(), that.getRealizationEpoch(), mode) &&
- deepEquals(getDomainOfValidity(), that.getDomainOfValidity(), mode) &&
- deepEquals(getAnchorPoint(), that.getAnchorPoint(), mode) &&
- deepEquals(getScope(), that.getScope(), mode);
+ deepEquals(getAnchorPoint(), that.getAnchorPoint(), mode);
}
default: {
/*
@@ -445,10 +375,11 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
* for more information.
*
* @return the hash code value. This value may change in any future Apache SIS version.
+ * @hidden because not useful.
*/
@Override
protected long computeHashCode() {
- return super.computeHashCode() + Objects.hash(anchorDefinition, realizationEpoch, domainOfValidity, scope);
+ return super.computeHashCode() + Objects.hash(anchorDefinition, realizationEpoch);
}
/**
@@ -525,30 +456,4 @@ public class AbstractDatum extends AbstractIdentifiedObject implements Datum {
ImplementationHelper.propertyAlreadySet(AbstractDatum.class, "setRealizationEpoch", "realizationEpoch");
}
}
-
- /**
- * Invoked by JAXB only at unmarshalling time.
- *
- * @see #getDomainOfValidity()
- */
- private void setDomainOfValidity(final Extent value) {
- if (domainOfValidity == null) {
- domainOfValidity = value;
- } else {
- ImplementationHelper.propertyAlreadySet(AbstractDatum.class, "setDomainOfValidity", "domainOfValidity");
- }
- }
-
- /**
- * Invoked by JAXB only at unmarshalling time.
- *
- * @see #getScope()
- */
- private void setScope(final InternationalString value) {
- if (scope == null) {
- scope = value;
- } else {
- ImplementationHelper.propertyAlreadySet(AbstractDatum.class, "setScope", "scope");
- }
- }
}
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEllipsoid.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEllipsoid.java
index 5c44473ef5..52541a511d 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEllipsoid.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEllipsoid.java
@@ -174,23 +174,19 @@ public class DefaultEllipsoid extends AbstractIdentifiedObject implements Ellips
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEngineeringDatum.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEngineeringDatum.java
index 8182b74b8f..b2ecb9c866 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEngineeringDatum.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultEngineeringDatum.java
@@ -67,47 +67,35 @@ public class DefaultEngineeringDatum extends AbstractDatum implements Engineerin
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link java.util.Date}</td>
* <td>{@link #getRealizationEpoch()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#SCOPE_KEY}</td>
- * <td>{@link InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the identified object.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultImageDatum.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultImageDatum.java
index e8a7ebae4e..59bed465f0 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultImageDatum.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultImageDatum.java
@@ -89,42 +89,31 @@ public class DefaultImageDatum extends AbstractDatum implements ImageDatum {
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link java.util.Date}</td>
* <td>{@link #getRealizationEpoch()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#SCOPE_KEY}</td>
- * <td>{@link InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the identified object.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultParametricDatum.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultParametricDatum.java
index 546fcc9098..fcc1742aaa 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultParametricDatum.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultParametricDatum.java
@@ -76,47 +76,35 @@ public class DefaultParametricDatum extends AbstractDatum implements ParametricD
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link org.opengis.metadata.Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
* <td>{@link #getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link Date}</td>
* <td>{@link #getRealizationEpoch()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#SCOPE_KEY}</td>
- * <td>{@link org.opengis.util.InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the identified object.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultPrimeMeridian.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultPrimeMeridian.java
index ac14fc0e64..88298107f5 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultPrimeMeridian.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultPrimeMeridian.java
@@ -127,23 +127,19 @@ public class DefaultPrimeMeridian extends AbstractIdentifiedObject implements Pr
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultTemporalDatum.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultTemporalDatum.java
index 823c80aaba..ebea1a3861 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultTemporalDatum.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultTemporalDatum.java
@@ -110,47 +110,35 @@ public class DefaultTemporalDatum extends AbstractDatum implements TemporalDatum
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link Date}</td>
* <td>{@link #getRealizationEpoch()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#SCOPE_KEY}</td>
- * <td>{@link InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the identified object.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultVerticalDatum.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultVerticalDatum.java
index d9bc0af021..5aec263977 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultVerticalDatum.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/datum/DefaultVerticalDatum.java
@@ -111,47 +111,35 @@ public class DefaultVerticalDatum extends AbstractDatum implements VerticalDatum
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link java.util.Date}</td>
* <td>{@link #getRealizationEpoch()}</td>
* </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link org.opengis.metadata.extent.Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.datum.Datum#SCOPE_KEY}</td>
- * <td>{@link InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
* </table>
*
* @param properties the properties to be given to the identified object.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/factory/GeodeticObjectFactory.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/factory/GeodeticObjectFactory.java
index 9b3ce167ab..85c2846cc2 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/factory/GeodeticObjectFactory.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/factory/GeodeticObjectFactory.java
@@ -41,7 +41,6 @@ import org.opengis.referencing.operation.*;
import org.opengis.parameter.ParameterNotFoundException;
import org.apache.sis.referencing.NamedIdentifier;
import org.apache.sis.referencing.IdentifiedObjects;
-import org.apache.sis.referencing.AbstractReferenceSystem;
import org.apache.sis.referencing.AbstractIdentifiedObject;
import org.apache.sis.referencing.cs.*;
import org.apache.sis.referencing.crs.*;
@@ -97,78 +96,67 @@ import org.apache.sis.xml.XML;
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link AbstractIdentifiedObject#getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#AUTHORITY_KEY}</td>
* <td>{@link String} or {@link org.opengis.metadata.citation.Citation}</td>
* <td>{@link NamedIdentifier#getAuthority()} on the {@linkplain AbstractIdentifiedObject#getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#CODE_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getCode()} on the {@linkplain AbstractIdentifiedObject#getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#CODESPACE_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getCodeSpace()} on the {@linkplain AbstractIdentifiedObject#getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#VERSION_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getVersion()} on the {@linkplain AbstractIdentifiedObject#getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.metadata.Identifier#DESCRIPTION_KEY}</td>
* <td>{@link String}</td>
* <td>{@link NamedIdentifier#getDescription()} on the {@linkplain AbstractIdentifiedObject#getName() name}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link AbstractIdentifiedObject#getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link AbstractIdentifiedObject#getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.ReferenceSystem#DOMAIN_OF_VALIDITY_KEY}</td>
* <td>{@link Extent}</td>
- * <td>{@link AbstractReferenceSystem#getDomainOfValidity()}</td>
- * </tr>
- * <tr>
+ * <td>{@link DefaultObjectDomain#getDomainOfValidity()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.ReferenceSystem#SCOPE_KEY}</td>
* <td>{@link String} or {@link InternationalString}</td>
- * <td>{@link AbstractReferenceSystem#getScope()}</td>
- * </tr>
- * <tr>
+ * <td>{@link DefaultObjectDomain#getScope()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#ANCHOR_POINT_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link AbstractDatum#getAnchorPoint()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.datum.Datum#REALIZATION_EPOCH_KEY}</td>
* <td>{@link Date}</td>
* <td>{@link AbstractDatum#getRealizationEpoch()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link AbstractIdentifiedObject#getRemarks()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.apache.sis.referencing.AbstractIdentifiedObject#DEPRECATED_KEY}</td>
* <td>{@link Boolean}</td>
* <td>{@link AbstractIdentifiedObject#isDeprecated()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.apache.sis.referencing.AbstractIdentifiedObject#LOCALE_KEY}</td>
* <td>{@link Locale}</td>
* <td>(none)</td>
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java
index 8732d7bb0f..adeeb82046 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/AbstractCoordinateOperation.java
@@ -31,7 +31,6 @@ import jakarta.xml.bind.annotation.XmlRootElement;
import javax.measure.IncommensurableException;
import org.opengis.util.InternationalString;
import org.opengis.metadata.Identifier;
-import org.opengis.metadata.extent.Extent;
import org.opengis.metadata.quality.PositionalAccuracy;
import org.opengis.referencing.IdentifiedObject;
import org.opengis.referencing.crs.GeographicCRS;
@@ -51,7 +50,6 @@ import org.apache.sis.io.wkt.Convention;
import org.apache.sis.util.Classes;
import org.apache.sis.util.ComparisonMode;
import org.apache.sis.util.UnsupportedImplementationException;
-import org.apache.sis.util.iso.Types;
import org.apache.sis.util.collection.Containers;
import org.apache.sis.util.logging.Logging;
import org.apache.sis.util.resources.Errors;
@@ -109,8 +107,6 @@ import static org.apache.sis.util.Utilities.deepEquals;
* @since 0.6
*/
@XmlType(name = "AbstractCoordinateOperationType", propOrder = {
- "domainOfValidity",
- "scope",
"operationVersion",
"accuracy",
"source",
@@ -126,7 +122,7 @@ public class AbstractCoordinateOperation extends AbstractIdentifiedObject implem
/**
* Serial number for inter-operability with different versions.
*/
- private static final long serialVersionUID = 1237358357729193885L;
+ private static final long serialVersionUID = -5441746770453401219L;
/**
* The logger for coordinate operations.
@@ -192,29 +188,6 @@ public class AbstractCoordinateOperation extends AbstractIdentifiedObject implem
@SuppressWarnings("serial") // Most SIS implementations are serializable.
Collection<PositionalAccuracy> coordinateOperationAccuracy;
- /**
- * Area in which this operation is valid, or {@code null} if not available.
- *
- * <p><b>Consider this field as final!</b>
- * This field is non-final only for the convenience of constructors and for initialization
- * at XML unmarshalling time by {@link #setDomainOfValidity(Extent)}.</p>
- *
- * @see #getDomainOfValidity()
- */
- @SuppressWarnings("serial") // Most SIS implementations are serializable.
- Extent domainOfValidity;
-
- /**
- * Description of domain of usage, or limitations of usage, for which this operation is valid.
- *
- * <p><b>Consider this field as final!</b>
- * This field is modified only at unmarshalling time by {@link #setScope(InternationalString)}.</p>
- *
- * @see #getScope()
- */
- @SuppressWarnings("serial") // Most SIS implementations are serializable.
- private InternationalString scope;
-
/**
* Transform from positions in the {@linkplain #getSourceCRS source coordinate reference system}
* to positions in the {@linkplain #getTargetCRS target coordinate reference system}.
@@ -251,8 +224,6 @@ public class AbstractCoordinateOperation extends AbstractIdentifiedObject implem
*/
AbstractCoordinateOperation(final Map<String,?> properties) {
super(properties);
- this.scope = Types.toInternationalString(properties, SCOPE_KEY);
- this.domainOfValidity = Containers.property(properties, DOMAIN_OF_VALIDITY_KEY, Extent.class);
this.operationVersion = Containers.property(properties, OPERATION_VERSION_KEY, String.class);
Object value = properties.get(COORDINATE_OPERATION_ACCURACY_KEY);
if (value != null) {
@@ -276,46 +247,33 @@ public class AbstractCoordinateOperation extends AbstractIdentifiedObject implem
* <th>Property name</th>
* <th>Value type</th>
* <th>Returned by</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.operation.CoordinateOperation#OPERATION_VERSION_KEY}</td>
* <td>{@link String}</td>
* <td>{@link #getOperationVersion()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.operation.CoordinateOperation#COORDINATE_OPERATION_ACCURACY_KEY}</td>
* <td>{@link PositionalAccuracy} (optionally as array)</td>
* <td>{@link #getCoordinateOperationAccuracy()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.operation.CoordinateOperation#DOMAIN_OF_VALIDITY_KEY}</td>
- * <td>{@link Extent}</td>
- * <td>{@link #getDomainOfValidity()}</td>
- * </tr>
- * <tr>
- * <td>{@value org.opengis.referencing.operation.CoordinateOperation#SCOPE_KEY}</td>
- * <td>{@link InternationalString} or {@link String}</td>
- * <td>{@link #getScope()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <th colspan="3" class="hsep">Defined in parent class (reminder)</th>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#NAME_KEY}</td>
* <td>{@link Identifier} or {@link String}</td>
* <td>{@link #getName()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#ALIAS_KEY}</td>
* <td>{@link org.opengis.util.GenericName} or {@link CharSequence} (optionally as array)</td>
* <td>{@link #getAlias()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#IDENTIFIERS_KEY}</td>
* <td>{@link Identifier} (optionally as array)</td>
* <td>{@link #getIdentifiers()}</td>
- * </tr>
- * <tr>
+ * </tr><tr>
+ * <td>{@value org.opengis.referencing.IdentifiedObject#DOMAINS_KEY}</td>
+ * <td>{@link org.opengis.referencing.ObjectDomain} (optionally as array)</td>
+ * <td>{@link #getDomains()}</td>
+ * </tr><tr>
* <td>{@value org.opengis.referencing.IdentifiedObject#REMARKS_KEY}</td>
* <td>{@link InternationalString} or {@link String}</td>
* <td>{@link #getRemarks()}</td>
@@ -444,8 +402,6 @@ check: for (int isTarget=0; ; isTarget++) { // 0 == source check; 1
interpolationCRS = getInterpolationCRS(operation);
operationVersion = operation.getOperationVersion();
coordinateOperationAccuracy = operation.getCoordinateOperationAccuracy();
- domainOfValidity = operation.getDomainOfValidity();
- scope = operation.getScope();
transform = operation.getMathTransform();
if (operation instanceof AbstractCoordinateOperation) {
wrapAroundChanges = ((AbstractCoordinateOperation) operation).wrapAroundChanges;
@@ -650,28 +606,6 @@ check: for (int isTarget=0; ; isTarget++) { // 0 == source check; 1
return PositionalAccuracyConstant.getLinearAccuracy(this);
}
- /**
- * Returns the area or region or timeframe in which this coordinate operation is valid.
- *
- * @return the coordinate operation valid domain, or {@code null} if not available.
- */
- @Override
- @XmlElement(name = "domainOfValidity")
- public Extent getDomainOfValidity() {
- return domainOfValidity;
- }
-
- /**
- * Returns a description of domain of usage, or limitations of usage, for which this operation is valid.
- *
- * @return a description of domain of usage, or {@code null} if none.
- */
- @Override
- @XmlElement(name = "scope", required = true)
- public InternationalString getScope() {
- return scope;
- }
-
/**
* Returns the object for transforming coordinates in the source CRS to coordinates in the target CRS.
* The transform may be {@code null} if this coordinate operation is a defining conversion.
@@ -826,8 +760,6 @@ check: for (int isTarget=0; ; isTarget++) { // 0 == source check; 1
if (Objects.equals(sourceCRS, that.sourceCRS) &&
Objects.equals(interpolationCRS, that.interpolationCRS) &&
Objects.equals(transform, that.transform) &&
- Objects.equals(scope, that.scope) &&
- Objects.equals(domainOfValidity, that.domainOfValidity) &&
Objects.equals(coordinateOperationAccuracy, that.coordinateOperationAccuracy))
{
// Check against never-ending recursivity with DerivedCRS.
@@ -850,9 +782,7 @@ check: for (int isTarget=0; ; isTarget++) { // 0 == source check; 1
*/
final CoordinateOperation that = (CoordinateOperation) object;
if ((mode.isIgnoringMetadata() ||
- (deepEquals(getScope(), that.getScope(), mode) &&
- deepEquals(getDomainOfValidity(), that.getDomainOfValidity(), mode) &&
- deepEquals(getCoordinateOperationAccuracy(), that.getCoordinateOperationAccuracy(), mode))) &&
+ (deepEquals(getCoordinateOperationAccuracy(), that.getCoordinateOperationAccuracy(), mode))) &&
deepEquals(getInterpolationCRS(), getInterpolationCRS(that), mode))
{
/*
@@ -1168,32 +1098,6 @@ check: for (int isTarget=0; ; isTarget++) { // 0 == source check; 1
}
}
- /**
- * Invoked by JAXB only at unmarshalling time.
- *
- * @see #getDomainOfValidity()
- */
- private void setDomainOfValidity(final Extent value) {
- if (domainOfValidity == null) {
- domainOfValidity = value;
- } else {
- ImplementationHelper.propertyAlreadySet(AbstractCoordinateOperation.class, "setDomainOfValidity", "domainOfValidity");
- }
- }
-
- /**
- * Invoked by JAXB only at unmarshalling time.
- *
- * @see #getScope()
- */
- private void setScope(final InternationalString value) {
- if (scope == null) {
- scope = value;
- } else {
- ImplementationHelper.propertyAlreadySet(AbstractCoordinateOperation.class, "setScope", "scope");
- }
- }
-
/**
* Invoked by JAXB after unmarshalling.
* May be overridden by subclasses.
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java
index 3fb16f3a3a..527621ad07 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/operation/DefaultConcatenatedOperation.java
@@ -24,7 +24,6 @@ import jakarta.xml.bind.annotation.XmlType;
import jakarta.xml.bind.annotation.XmlElement;
import jakarta.xml.bind.annotation.XmlRootElement;
import org.opengis.util.FactoryException;
-import org.opengis.metadata.extent.Extent;
import org.opengis.geometry.MismatchedDimensionException;
import org.opengis.referencing.crs.CoordinateReferenceSystem;
import org.opengis.referencing.operation.CoordinateOperation;
@@ -135,7 +134,7 @@ final class DefaultConcatenatedOperation extends AbstractCoordinateOperation imp
{
final List<CoordinateOperation> flattened = new ArrayList<>(operations.length);
final CoordinateReferenceSystem crs = initialize(properties, operations, flattened, mtFactory,
- (sourceCRS == null), (coordinateOperationAccuracy == null), (domainOfValidity == null));
+ (sourceCRS == null), (coordinateOperationAccuracy == null));
if (targetCRS == null) {
targetCRS = crs;
}
@@ -183,7 +182,6 @@ final class DefaultConcatenatedOperation extends AbstractCoordinateOperation imp
* @param mtFactory the math transform factory to use, or {@code null} for not performing concatenation.
* @param setSource {@code true} for setting the {@link #sourceCRS} on the very first CRS (regardless if null or not).
* @param setAccuracy {@code true} for setting the {@link #coordinateOperationAccuracy} field.
- * @param setDomain {@code true} for setting the {@link #domainOfValidity} field.
* @return the last target CRS, regardless if null or not.
* @throws FactoryException if the factory cannot concatenate the math transforms.
*/
@@ -192,9 +190,8 @@ final class DefaultConcatenatedOperation extends AbstractCoordinateOperation imp
final CoordinateOperation[] operations,
final List<CoordinateOperation> flattened,
final MathTransformFactory mtFactory,
- boolean setSource,
- boolean setAccuracy,
- boolean setDomain) throws FactoryException
+ boolean setSource,
+ boolean setAccuracy) throws FactoryException
{
CoordinateReferenceSystem previous = null;
for (int i=0; i<operations.length; i++) {
@@ -235,7 +232,7 @@ final class DefaultConcatenatedOperation extends AbstractCoordinateOperation imp
if (op instanceof ConcatenatedOperation) {
final List<? extends CoordinateOperation> children = ((ConcatenatedOperation) op).getOperations();
final CoordinateOperation[] asArray = children.toArray(CoordinateOperation[]::new);
- initialize(properties, asArray, flattened, (step == null) ? mtFactory : null, false, setAccuracy, setDomain);
+ initialize(properties, asArray, flattened, (step == null) ? mtFactory : null, false, setAccuracy);
} else if (!step.isIdentity()) {
flattened.add(op);
}
@@ -260,21 +257,6 @@ final class DefaultConcatenatedOperation extends AbstractCoordinateOperation imp
setAccuracy = false;
}
}
- /*
- * Optionally copy the domain of validity, provided that it is the same for all component.
- * Current implementation does not try to compute the intersection of all components.
- */
- if (setDomain) {
- final Extent domain = op.getDomainOfValidity();
- if (domain != null) {
- if (domainOfValidity == null) {
- domainOfValidity = domain;
- } else if (!domain.equals(domainOfValidity)) {
- domainOfValidity = null;
- setDomain = false;
- }
- }
- }
}
return previous;
}
diff --git a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/util/WKTKeywords.java b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/util/WKTKeywords.java
index 1f6717f78e..4a7e5c19d0 100644
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/util/WKTKeywords.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/util/WKTKeywords.java
@@ -38,7 +38,7 @@ import org.apache.sis.util.ArraysExt;
*
* @author Martin Desruisseaux (Geomatys)
* @author Johann Sorel (Geomatys)
- * @version 1.2
+ * @version 1.4
*
* @see <a href="http://docs.opengeospatial.org/is/12-063r5/12-063r5.html">WKT 2 specification</a>
* @see <a href="http://www.geoapi.org/3.0/javadoc/org/opengis/referencing/doc-files/WKT.html">Legacy WKT 1</a>
@@ -62,6 +62,7 @@ public final class WKTKeywords extends Static {
Citation = "Citation",
Authority = "Authority",
Anchor = "Anchor",
+ Usage = "Usage",
Scope = "Scope",
Area = "Area",
Remark = "Remark";
diff --git a/endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/base/Capability.java b/endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/base/Capability.java
index 30318ece50..4b53214952 100644
--- a/endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/base/Capability.java
+++ b/endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/base/Capability.java
@@ -98,7 +98,7 @@ public enum Capability {
}
}
if (capabilities == null) {
- capabilities = resources.getString(Vocabulary.Keys.Unknown);
+ capabilities = resources.getString(Vocabulary.Keys.NotKnown);
}
/*
* Get a title for the format, followed by the short name between parenthesis
diff --git a/endorsed/src/org.apache.sis.util/main/org/apache/sis/setup/About.java b/endorsed/src/org.apache.sis.util/main/org/apache/sis/setup/About.java
index c386225d72..d0819dc2c9 100644
--- a/endorsed/src/org.apache.sis.util/main/org/apache/sis/setup/About.java
+++ b/endorsed/src/org.apache.sis.util/main/org/apache/sis/setup/About.java
@@ -364,7 +364,7 @@ fill: for (int i=0; ; i++) {
final Level level = getLogger("").getLevel(); // Root logger level.
if (level == null) {
// May happen when some code outside Apache SIS define their own loggers.
- value = resources.getString(Vocabulary.Keys.Unknown);
+ value = resources.getString(Vocabulary.Keys.NotKnown);
} else {
value = level.getLocalizedName();
final Map<String,Level> levels = Loggers.getEffectiveLevels();
diff --git a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/ResourceInternationalString.java b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/ResourceInternationalString.java
index d60d9ac5b4..7f5325b6d5 100644
--- a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/ResourceInternationalString.java
+++ b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/ResourceInternationalString.java
@@ -32,8 +32,8 @@ import org.apache.sis.util.AbstractInternationalString;
/**
* A copy of {@link org.apache.sis.util.ResourceInternationalString} specialized for
- * {@link IndexedResourceBundle}. Compared to the public class, this specialization works
- * with integer resource keys and accepts arguments.
+ * {@link IndexedResourceBundle}. Compared to the public class, this specialization
+ * works with integer resource keys and accepts arguments.
*
* <h2>Immutability and thread safety</h2>
* This base class is immutable and thus inherently thread-safe.
diff --git a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.java b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.java
index 223f270f75..4d26c8a2fb 100644
--- a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.java
+++ b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.java
@@ -882,6 +882,11 @@ public class Vocabulary extends IndexedResourceBundle {
*/
public static final short NorthBound = 142;
+ /**
+ * Not known
+ */
+ public static final short NotKnown = 207;
+
/**
* Note
*/
@@ -1302,11 +1307,6 @@ public class Vocabulary extends IndexedResourceBundle {
*/
public static final short Units = 206;
- /**
- * Unknown
- */
- public static final short Unknown = 207;
-
/**
* Unnamed
*/
diff --git a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.properties b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.properties
index e3d1182324..471578feb2 100644
--- a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.properties
+++ b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary.properties
@@ -181,6 +181,7 @@ Nodata = No data
None = None
Note = Note
NorthBound = North bound
+NotKnown = Not known
NumberOfDimensions = Number of dimensions
NumberOfTiles = Number of tiles
NumberOfValues = Number of values
@@ -263,7 +264,6 @@ True = True
Type = Type
TypeOfResource = Type of resource
Units = Units
-Unknown = Unknown
Unnamed = Unnamed
Unnamed_1 = Unnamed #{0}
Unspecified = Unspecified
diff --git a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary_fr.properties b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary_fr.properties
index d804f40bca..a8ec92bc4b 100644
--- a/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary_fr.properties
+++ b/endorsed/src/org.apache.sis.util/main/org/apache/sis/util/resources/Vocabulary_fr.properties
@@ -188,6 +188,7 @@ Nodata = Absence de donn\u00e9es
None = Aucun
Note = Note
NorthBound = Limite nord
+NotKnown = Inconnu
NumberOfDimensions = Nombre de dimensions
NumberOfTiles = Nombre de tuiles
NumberOfValues = Nombre de valeurs
@@ -270,7 +271,6 @@ True = Vrai
Type = Type
TypeOfResource = Type de ressource
Units = Unit\u00e9s
-Unknown = Inconnu
Unnamed = Sans nom
Unnamed_1 = Sans nom \u2116{0}
Unspecified = Non-sp\u00e9cifi\u00e9
diff --git a/geoapi/snapshot b/geoapi/snapshot
index 5339fd99e2..28c89910b3 160000
--- a/geoapi/snapshot
+++ b/geoapi/snapshot
@@ -1 +1 @@
-Subproject commit 5339fd99e2315254ede82f24be44e46073b2bcb5
+Subproject commit 28c89910b35b3b3cba2ce4aeeeba1fabc732122b
diff --git a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/dataset/WindowHandler.java b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/dataset/WindowHandler.java
index 94b9e786ef..0fca43c91a 100644
--- a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/dataset/WindowHandler.java
+++ b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/dataset/WindowHandler.java
@@ -112,7 +112,7 @@ public abstract class WindowHandler {
} else try {
text = DataStoreOpener.findLabel(getResource(), manager.locale, true);
} catch (DataStoreException | RuntimeException e) {
- text = Vocabulary.getResources(manager.locale).getString(Vocabulary.Keys.Unknown);
+ text = Vocabulary.getResources(manager.locale).getString(Vocabulary.Keys.NotKnown);
Logging.recoverableException(LOGGER, WindowHandler.class, "<init>", e);
}
title.set(text);
diff --git a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/internal/DataStoreOpener.java b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/internal/DataStoreOpener.java
index f149d404cc..0b4d222e0c 100644
--- a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/internal/DataStoreOpener.java
+++ b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/internal/DataStoreOpener.java
@@ -208,7 +208,7 @@ public final class DataStoreOpener extends Task<DataStore> {
if (name == null) {
name = Strings.trimOrNull(IOUtilities.toString(source));
if (name == null) {
- name = Vocabulary.format(Vocabulary.Keys.Unknown);
+ name = Vocabulary.format(Vocabulary.Keys.NotKnown);
}
}
return name;
diff --git a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/referencing/CRSChooser.java b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/referencing/CRSChooser.java
index f5b84af6c1..507c76d116 100644
--- a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/referencing/CRSChooser.java
+++ b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/referencing/CRSChooser.java
@@ -376,7 +376,7 @@ public class CRSChooser extends Dialog<CoordinateReferenceSystem> {
else if (crs instanceof ProjectedCRS) {key = Vocabulary.Keys.Projected; expected = 2;}
else if (crs instanceof EngineeringCRS) {key = Vocabulary.Keys.Engineering; expected = 0;}
else {
- key = Vocabulary.Keys.Unknown;
+ key = Vocabulary.Keys.NotKnown;
expected = 0;
}
String text = Vocabulary.getResources(locale).getString(key);
[sis] 01/02: Skip the Ivy task if the "dependencies" directory is already present.
Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a commit to branch geoapi-4.0
in repository https://gitbox.apache.org/repos/asf/sis.git
commit abafcba8a2d5fbcd448cd3432f5e3dd304108d32
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Tue Aug 29 10:26:02 2023 +0200
Skip the Ivy task if the "dependencies" directory is already present.
---
netbeans-project/build.xml | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/netbeans-project/build.xml b/netbeans-project/build.xml
index af190283ca..0f39937cb2 100644
--- a/netbeans-project/build.xml
+++ b/netbeans-project/build.xml
@@ -25,7 +25,12 @@
configure NetBeans with `-add-reads` and `-add-exports` javac
arguments for test compilation only.
-->
- <target name="-pre-compile">
+ <target name="dir.check">
+ <condition property="dir.exists">
+ <available file="build/dependencies" type="dir"/>
+ </condition>
+ </target>
+ <target name="-pre-compile" depends="dir.check" unless="dir.exists">
<ivy:settings file="ivy-settings.xml"/>
<ivy:retrieve pattern="build/dependencies/[artifact].[ext]" symlink="true" sync="true"/>
<symlink link="${basedir}/build/dependencies/geoapi-pending.jar"