This is an automated email from the ASF dual-hosted git repository. jsorel pushed a commit to branch feat/coverage-json in repository https://gitbox.apache.org/repos/asf/sis.git
The following commit(s) were added to refs/heads/feat/coverage-json by this push: new c2d1330e80 fix(CoverageJson): use CRS URN if it exist c2d1330e80 is described below commit c2d1330e802a8d578ddbed6fde14bfa451e3145c Author: jsorel <johann.so...@geomatys.com> AuthorDate: Fri May 26 08:43:09 2023 +0200 fix(CoverageJson): use CRS URN if it exist --- .../java/org/apache/sis/internal/coveragejson/CoverageResource.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/storage/sis-coveragejson/src/main/java/org/apache/sis/internal/coveragejson/CoverageResource.java b/storage/sis-coveragejson/src/main/java/org/apache/sis/internal/coveragejson/CoverageResource.java index 8c269bd754..19a1eb737a 100644 --- a/storage/sis-coveragejson/src/main/java/org/apache/sis/internal/coveragejson/CoverageResource.java +++ b/storage/sis-coveragejson/src/main/java/org/apache/sis/internal/coveragejson/CoverageResource.java @@ -700,6 +700,9 @@ public final class CoverageResource extends AbstractGridCoverageResource { } private static String toURI(CoordinateReferenceSystem crs) throws FactoryException, DataStoreException { + String urn = IdentifiedObjects.lookupURN(crs, null); + if (urn != null && !urn.isBlank()) return urn; + final Integer code = IdentifiedObjects.lookupEPSG(crs); if (code == null) { if (crs instanceof org.opengis.referencing.crs.GeographicCRS) {