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 2025/01/24 16:25:50 UTC
(sis) branch main updated (1531118a77 -> ae65a8be08)
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a change to branch main
in repository https://gitbox.apache.org/repos/asf/sis.git
from 1531118a77 Merge branch 'geoapi-4.0': automatic reorganization of imports.
add 2cfb383a96 Merge branch 'geoapi-4.0' into geoapi-3.1
add 90a499a32d Resolve a "unspecified CRS" exception when reading a GeoTIFF with a three-dimensional CRS (a geographic or projected CRS + a vertical CRS on user-defined datum).
add afb365202e Make the code more SecurityException-proof. This commit does not introduce new dependency since the Apache SIS code already had some `catch (SecurityException)` statements. While the security manager is removed in Java 24, SIS can run on Java 11 and some softwares are still running in security-constrained environments. This commit will be reverted when Apache SIS will require Java 24, or when the `SecurityException` class will be deprecated.
add 416551cdc7 Add a public `Configuration.shutdown()` method.
add 7a696fe83a Change the order of `AxesConvention` enumeration values from most conservative to most aggressive.
add 66809d27ae Handle empty files as non-existent files when opening a `DataStore` in write mode. This is needed because when requesting a temporary file, an empty file is created.
add e93449f33c Document an extra step needed for a more complete shutdown of the system.
add 6cdeffb8f5 Add a `DataStores.open(Object, String)` method which allows to specify the preferred data store implementation.
add 56de57f5b7 Add a `GridGeometry.getOrigin()` method.
add e76f36ff59 Avoid a NullPointerException when a GeoTIFF file has incomplete georeferencing information.
add a1b220381e Relax the check for the number of dimensions when the grid coverage has less dimensions than expected. Normally, the number of dimensions of the tiles should be equal to the number of dimensions declared in the grid extent. However, it happens sometime that the `TiledGridResource` is a two dimensional image associated to a three-dimensional CRS. This is not recommended, but can happen with GeoTIFF for example. What to do with the extra dimensions is unclear (the GeoTIF [...]
add 08710309d3 Upgrade GeoAPI snapshot version. Contains the addition of `getReferenceSystemType()` method. This upgrade fixes https://issues.apache.org/jira/browse/SIS-470
add bbe24a2fba Better checks of SampleModel properties before to write a GeoTIFF file.
add 08e4257586 Better checks of ColorModel properties before to write a GeoTIFF file.
add f42386f4e9 Rename `ColorModelBuilder` as `ColorScaleBuilder` for reflecting the fact that it is about indexed color model, and for making the `ColorModelBuilder` name available for a builder for other cases.
add c9a672132b Move the `createPackedRGB(…)` and createBandedRGB(…)` methods in a new `ColorModelBuilder` class. In gives more flexibility for configuring the RGB color model to create.
add 61589faccb Rename `MultiSourceLayout` and `BandAggregateLayout` for making clear that this is about band aggregate only rather than all multi-source image.
add acdc884394 Add an image overlay operation in `ImageProcessor`.
add 6a22d7e5e9 If an image does not fit the requirement of the TIFF specification, reformat the image before to write it in a TIFF file.
add aeaadf2f05 GeoTIFF writer should throw an exception instead of logging a warning when the CRS or the "grid to CRS" transform cannot be encoded.
add 65d1d016d1 In case of error while writing a GeoTIFF file, restore the file to its previous state.
add a95fbd4ab4 Allow GeoTIFF writer to encode "grid to CRS" where the vertical component is non-linear.
add ae291c6dec Delete leftover temporary files during Geopackage test.
add 78771af452 Avoid triple-slash for starting a comment, because they are reserved for Markdown in latest Java versions.
add 11790ff20e Accept also regions encoded as character strings instead of as an instance of the Region class.
add 97f67d1dc8 Revisit the S3 documentation for reducing a confusion about what S3 call "key". In the context of Apache SIS, a S3 "key" is interpreted as a file path. Furthermore, "key" was too easily confused with "access key".
add 72ce0be904 Upgrade Amazon S3 dependency from 2.26.24 to 2.29.37.
add 0173414d34 `Extents.getVerticalRange(…)` may throw an exception when a value is NaN.
add ed889b8433 Fix an `IndexArrayOutOfBoundsException` when reading a GeoTIFF with a three-dimensional CRS.
add 6718873520 Add the netCDF attribute names of Mercator data (from Copernicus) as an alternative convention when CF attributes were not found. Those alternatives are ignored when CF attributes are found.
add 076c21a2c1 Add a `PlanarImage.getValidArea()` method. `ResampledImage` computes this information by reprojecting the valid area of the source.
add 4349cc81c8 More accurate checks by `ImageOverlay` of which sources are worth to keep. This is using the `getValidArea()` method added in the previous commit.
add 8c9c31766b Fix: calculation of contributions in `ImageOverlay` was too large. Edit documentation by saying that each image is fully opaque.
add 1b0067787b Remove the `horizontal` boolean argument in `ShapeUtilities.parabolicControlPoint(…)`. It was never used.
add 69eedf135e Move three `ImageLayout` constants to the classes where they are used. Opportunistic renaming of a field for clarity and rewording in Javadoc. This is in preparation for moving `ImageLayout` to public API.
add cc2e967908 Retrofit user-provided arguments as `ImageLayout` properties: - The `allowPartialTiles` argument given to `ImageLayout` methods. - The `ImageProcessor.autoTileSize` field.
add e0d5eb16e4 Move `ImageLayout` to public API. The intend is to use it as a replacement for `SampleModel` and `ColorModel` arguments in `ImageProcessor`.
add 226c9c5706 Deprecate `ImageProcessor.Resizing`, replaced by `ImageLayout`.
add 49945796f4 Retrofit the `minTile` property of two `ImageLayout` subclasses into `ImageLayout` directly.
add b9f98ce7e1 Add `SampleModel` and `ColorModel` properties into `ImageLayout` in replacement for optional arguments given to image processor.
add 8018b22551 Remove the `ColorModel` property from `ImageLayout` for avoiding an overlap with `Colorizer`.
add 2a7346399c Consolidation in the way that a sample model is created from an `ImageLayout` for an image operation. Some `int` arguments are replaced by more type-safe objects such as `DataType` or `Dimension`.
add bb8db50cd2 `BandAggregateLayout` does not need anymore to extend `ImageLayout`. This simplication makes easier to complete the constructor, for example with the concatenated list of sample dimensions.
add 482e27bf24 Consolidation of the handling of `PlanarImage.SAMPLE_DIMENSIONS_KEY`: - Document that some elements may be null, and adjust codes accordingly. - Ensure that `ImageProcessor.statistics(…)` never return null values. - Change some internal from `SampleDimensions[]` to `List<SampleDimension>`. It reduces the number of conversions between those two types.
add 49f489db9e Fix an `IndexOutOfBoundsException` when fetching netCDF metadata. Adjust the title of GeoTIFF file declared in metadata.
add cb303c4705 Document the relationship between `ImageCombiner` and `ImageProcessor.overlay(…)`.
add 9160018564 Merge branch 'geoapi-4.0' into geoapi-3.1. Contains bug fix related to GeoTIFF and other formats. Contains a new "overlay" image operation and improvement in the handling of image properties in "band aggregate" operation.
new 84a6d62055 Merge branch 'geoapi-3.1'
add 8fdc1e93a3 Rename `SampleModelFactory` as `SampleModelBuilder` (internal class).
add 85b775cfa2 Move the `org.apache.sis.coverage.privy` classes related to image handling to a separated `org.apache.sis.image.privy` package. This is change in SIS internal only, with no impact on public API. This commit has no code change other than the move.
add 8c6d8cca43 Remove a duplicated localized resource.
add 630a996a08 Merge branch 'geoapi-4.0' into geoapi-3.1. Contains only class or package renaming.
new 4bd7092a20 Merge branch 'geoapi-3.1'
add 4049ee5d82 Add a DataType.UINT type for distinguishing whether Java2D `DataBuffer.TYPE_INT` should be interpreted as signed or unsigned. The sign of the integer type is ambiguous in Java2D, as it depends on the context. Methods were added in `DataType` for handling this ambiguity.
add 8ddfe3bb09 Slight simplification of `DataType` usage when mapping to Java primitive types.
add 6ff4ff2fa9 Add a `GeoTiffStoreProvider.open(ParameterValueGroup)` method for taking in account the compression and modifiers parameters.
add 37ca8154b9 Replace usage of legacy `StringTokenizer` by `String.split(…)` or alternatives.
add afa573ef65 Detect name collision in the fields reported by GDAL. It happens for example when using the Shapefile driver, because field names are truncated to 10 characters.
add 4c5563faad Merge branch 'geoapi-4.0' into geoapi-3.1
new ae65a8be08 Merge branch 'geoapi-3.1'
The 3 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:
.../sis/buildtools/coding/ReorganizeImports.java | 2 +-
.../org/apache/sis/buildtools/book/OGC.lst | 1 +
.../org/apache/sis/cloud/aws/s3/FileService.java | 36 +-
.../main/org/apache/sis/cloud/aws/s3/KeyPath.java | 4 +-
.../apache/sis/cloud/aws/s3/ObjectAttributes.java | 5 +-
.../org/apache/sis/cloud/aws/s3/package-info.java | 31 +-
.../org.apache.sis.feature/main/module-info.java | 5 +
.../coverage/grid/BandAggregateGridCoverage.java | 10 +-
.../coverage/grid/CoordinateOperationFinder.java | 2 +
.../apache/sis/coverage/grid/DefaultEvaluator.java | 2 +-
.../org/apache/sis/coverage/grid/GridCoverage.java | 5 +-
.../apache/sis/coverage/grid/GridCoverage2D.java | 4 +-
.../sis/coverage/grid/GridCoverageBuilder.java | 15 +-
.../sis/coverage/grid/GridCoverageProcessor.java | 8 +-
.../apache/sis/coverage/grid/GridDerivation.java | 6 +-
.../org/apache/sis/coverage/grid/GridGeometry.java | 219 +++++--
.../apache/sis/coverage/grid/ImageRenderer.java | 23 +-
.../apache/sis/coverage/grid/SliceGeometry.java | 2 +-
...rceArgument.java => BandAggregateArgument.java} | 8 +-
.../org/apache/sis/coverage/privy/ImageLayout.java | 458 --------------
.../apache/sis/coverage/privy/RangeArgument.java | 6 +-
.../sis/coverage/privy/SampleDimensions.java | 27 +-
.../org/apache/sis/feature/DefaultFeatureType.java | 17 +-
.../sis/feature/builder/FeatureTypeBuilder.java | 14 +-
.../org/apache/sis/feature/internal/Resources.java | 3 +-
.../sis/feature/internal/Resources.properties | 2 +-
.../sis/feature/internal/Resources_fr.properties | 2 +-
.../apache/sis/feature/privy/FeatureUtilities.java | 6 +
.../main/org/apache/sis/image/AnnotatedImage.java | 4 +-
.../org/apache/sis/image/BandAggregateImage.java | 127 +++-
...iSourceLayout.java => BandAggregateLayout.java} | 203 +++----
.../main/org/apache/sis/image/BandSelectImage.java | 26 +-
.../main/org/apache/sis/image/BandSharing.java | 2 +-
.../apache/sis/image/BandedSampleConverter.java | 53 +-
.../main/org/apache/sis/image/Colorizer.java | 44 +-
.../main/org/apache/sis/image/ComputedImage.java | 25 +-
.../main/org/apache/sis/image/DataType.java | 270 +++++++--
.../main/org/apache/sis/image/ImageAdapter.java | 4 +-
.../main/org/apache/sis/image/ImageCombiner.java | 36 +-
.../main/org/apache/sis/image/ImageLayout.java | 673 +++++++++++++++++++++
.../main/org/apache/sis/image/ImageOverlay.java | 431 +++++++++++++
.../main/org/apache/sis/image/ImageProcessor.java | 231 +++++--
.../main/org/apache/sis/image/MaskImage.java | 6 +-
.../main/org/apache/sis/image/MaskedImage.java | 6 +-
.../org/apache/sis/image/MultiSourceImage.java | 43 +-
.../org/apache/sis/image/MultiSourcePrefetch.java | 2 +-
.../main/org/apache/sis/image/PixelIterator.java | 14 +-
.../main/org/apache/sis/image/PlanarImage.java | 77 ++-
.../sis/image/PositionalConsistencyImage.java | 2 +-
.../main/org/apache/sis/image/PrefetchedImage.java | 8 +-
.../main/org/apache/sis/image/RecoloredImage.java | 67 +-
.../main/org/apache/sis/image/ResampledImage.java | 70 ++-
.../org/apache/sis/image/SourceAlignedImage.java | 10 +
.../org/apache/sis/image/StatisticsCalculator.java | 15 +-
.../main/org/apache/sis/image/Transferer.java | 9 +-
.../main/org/apache/sis/image/Visualization.java | 80 +--
.../apache/sis/image/WritableComputedImage.java | 4 +-
.../privy/BatchComputedImage.java | 2 +-
.../apache/sis/image/privy/ColorModelBuilder.java | 304 ++++++++++
.../privy/ColorModelFactory.java | 65 +-
.../{coverage => image}/privy/ColorModelType.java | 4 +-
.../privy/ColorScaleBuilder.java} | 63 +-
.../{coverage => image}/privy/ColorsForRange.java | 8 +-
.../privy/DeferredProperty.java | 2 +-
.../sis/{coverage => image}/privy/FillValues.java | 2 +-
.../{coverage => image}/privy/ImageUtilities.java | 133 ++--
.../privy/MultiBandsIndexColorModel.java | 2 +-
.../{coverage => image}/privy/ObservableImage.java | 2 +-
.../{coverage => image}/privy/RasterFactory.java | 13 +-
.../privy/SampleModelBuilder.java} | 93 ++-
.../privy/ScaledColorModel.java | 2 +-
.../privy/ScaledColorSpace.java | 2 +-
.../privy/TileErrorHandler.java | 2 +-
.../{coverage => image}/privy/TileOpExecutor.java | 2 +-
.../{coverage => image}/privy/TilePlaceholder.java | 7 +-
.../sis/{coverage => image}/privy/TiledImage.java | 2 +-
.../privy/WritableTiledImage.java | 2 +-
.../{coverage => image}/privy/package-info.java | 4 +-
.../sis/coverage/grid/GridCoverage2DTest.java | 2 +-
.../apache/sis/coverage/grid/GridGeometryTest.java | 15 +-
.../coverage/grid/ResampledGridCoverageTest.java | 2 +-
.../coverage/grid/TranslatedGridCoverageTest.java | 2 +-
.../apache/sis/image/BandAggregateImageTest.java | 70 ++-
.../org/apache/sis/image/BandSelectImageTest.java | 4 +-
.../sis/image/BandedSampleConverterTest.java | 17 +-
.../test/org/apache/sis/image/DataTypeTest.java | 42 +-
.../{coverage/privy => image}/ImageLayoutTest.java | 14 +-
.../org/apache/sis/image/ImageOverlayTest.java | 116 ++++
.../org/apache/sis/image/InterpolationTest.java | 2 +-
.../test/org/apache/sis/image/MaskedImageTest.java | 2 +-
.../test/org/apache/sis/image/PlanarImageTest.java | 2 +-
.../org/apache/sis/image/ResampledImageTest.java | 24 +-
.../apache/sis/image/StatisticsCalculatorTest.java | 2 +-
.../test/org/apache/sis/image/TiledImageMock.java | 4 +-
.../privy/ColorModelBuilderTest.java | 15 +-
.../privy/ImageUtilitiesTest.java | 18 +-
.../privy/SampleModelBuilderTest.java} | 50 +-
.../privy/ScaledColorSpaceTest.java | 2 +-
.../sis/image/processing/isoline/IsolinesTest.java | 2 +-
.../apache/sis/metadata/iso/extent/Extents.java | 5 +-
.../sis/metadata/privy/ReferencingServices.java | 20 +-
.../apache/sis/metadata/sql/MetadataWriter.java | 8 +-
.../apache/sis/metadata/sql/privy/Initializer.java | 7 +-
.../sis/metadata/sql/privy/LocalDataSource.java | 9 +-
.../apache/sis/metadata/sql/privy/SQLBuilder.java | 13 +-
.../main/org/apache/sis/xml/MarshallerPool.java | 12 +-
.../apache/sis/xml/bind/IdentifierMapAdapter.java | 16 +-
.../sis/xml/bind/ModifiableIdentifierMap.java | 16 +-
.../org/apache/sis/xml/bind/TypeRegistration.java | 8 +-
.../metadata/replace/ReferenceSystemMetadata.java | 8 +-
.../apache/sis/metadata/PropertyAccessorTest.java | 19 +-
.../org/apache/sis/map/coverage/RenderingData.java | 23 +-
.../sis/map/coverage/RenderingWorkaround.java | 2 +-
.../main/org/apache/sis/io/wkt/Element.java | 20 +-
.../main/org/apache/sis/io/wkt/Formatter.java | 56 +-
.../apache/sis/referencing/AuthorityFactories.java | 9 +-
.../main/org/apache/sis/referencing/CommonCRS.java | 5 +-
.../sis/referencing/crs/DefaultCompoundCRS.java | 2 +-
.../apache/sis/referencing/cs/AxesConvention.java | 218 +++----
.../factory/ConcurrentAuthorityFactory.java | 4 +-
.../sis/referencing/factory/sql/EPSGInstaller.java | 22 +-
.../referencing/internal/ServicesForMetadata.java | 20 +-
.../operation/CoordinateOperationFinder.java | 68 +--
.../provider/FranceGeocentricInterpolation.java | 18 +-
.../operation/provider/MapProjection.java | 14 +-
.../transform/AbstractMathTransform2D.java | 31 +-
.../transform/ConcatenatedTransform2D.java | 2 +-
.../transform/ConcatenatedTransformDirect2D.java | 2 +-
.../transform/DefaultMathTransformFactory.java | 12 +-
.../InterpolatedGeocentricTransform2D.java | 4 +-
.../transform/InterpolatedTransform2D.java | 4 +-
.../operation/transform/MolodenskyTransform2D.java | 2 +-
.../transform/PassThroughTransform2D.java | 2 +-
.../operation/transform/ProjectiveTransform2D.java | 2 +-
.../transform/SpecializableTransform2D.java | 4 +-
.../sis/referencing/privy/ShapeUtilities.java | 105 ++--
.../operation/CoordinateOperationFinderTest.java | 10 +-
.../referencing/operation/provider/NADCONTest.java | 10 +-
.../referencing/operation/provider/NTv2Test.java | 10 +-
.../sis/referencing/privy/ShapeUtilitiesTest.java | 23 +-
.../referencing/privy/ShapeUtilitiesViewer.java | 10 +-
.../sis/storage/geotiff/CompressedSubset.java | 2 +-
.../org/apache/sis/storage/geotiff/DataSubset.java | 8 +-
.../apache/sis/storage/geotiff/FormatModifier.java | 14 +-
.../apache/sis/storage/geotiff/GeoTiffStore.java | 29 +-
.../sis/storage/geotiff/GeoTiffStoreProvider.java | 57 +-
.../sis/storage/geotiff/ImageFileDirectory.java | 227 ++++---
.../org/apache/sis/storage/geotiff/Writer.java | 157 +++--
.../storage/geotiff/inflater/CopyFromBytes.java | 5 +-
.../geotiff/inflater/HorizontalPredictor.java | 5 +-
.../sis/storage/geotiff/reader/CRSBuilder.java | 68 ++-
.../geotiff/reader/GridGeometryBuilder.java | 32 +-
.../sis/storage/geotiff/reader/Localization.java | 1 +
.../sis/storage/geotiff/writer/GeoEncoder.java | 239 +++++---
.../geotiff/writer/HorizontalPredictor.java | 5 +-
.../storage/geotiff/writer/ReformattedImage.java | 230 +++++--
.../sis/storage/geotiff/writer/TileMatrix.java | 83 ++-
.../sis/storage/geotiff/GeoTiffStoreTest.java | 111 ++++
.../org/apache/sis/storage/geotiff/WriterTest.java | 26 +-
.../apache/sis/storage/netcdf/AttributeNames.java | 30 +
.../apache/sis/storage/netcdf/MetadataReader.java | 28 +-
.../apache/sis/storage/netcdf/base/Convention.java | 15 +-
.../apache/sis/storage/netcdf/base/DataType.java | 2 +-
.../sis/storage/netcdf/base/RasterResource.java | 2 +-
.../sis/storage/sql/postgis/RasterReader.java | 7 +-
.../sis/storage/xml/stream/StaxStreamReader.java | 10 +-
.../sis/storage/xml/stream/StaxStreamWriter.java | 10 +-
.../apache/sis/io/stream/ChannelDataOutput.java | 28 +
.../org/apache/sis/io/stream/ChannelFactory.java | 46 +-
.../apache/sis/io/stream/HyperRectangleWriter.java | 246 ++++++--
.../main/org/apache/sis/io/stream/IOUtilities.java | 16 +
.../main/org/apache/sis/io/stream/Region.java | 30 +
.../org/apache/sis/storage/DataStoreProvider.java | 22 +-
.../org/apache/sis/storage/DataStoreRegistry.java | 47 +-
.../main/org/apache/sis/storage/DataStores.java | 63 +-
.../sis/storage/IncompatibleResourceException.java | 56 +-
.../org/apache/sis/storage/ProbeProviderPair.java | 6 +-
.../main/org/apache/sis/storage/ProbeResult.java | 10 +-
.../org/apache/sis/storage/StorageConnector.java | 15 +-
.../aggregate/BandAggregateGridResource.java | 10 +-
.../aggregate/ConcatenatedGridCoverage.java | 2 +-
.../apache/sis/storage/base/MetadataBuilder.java | 43 +-
.../sis/storage/base/TiledDeferredImage.java | 2 +-
.../apache/sis/storage/base/TiledGridCoverage.java | 12 +-
.../apache/sis/storage/base/TiledGridResource.java | 53 +-
.../sis/storage/base/URIDataStoreProvider.java | 33 +-
.../sis/storage/base/WritableAggregateSupport.java | 2 +-
.../storage/base/WritableGridCoverageSupport.java | 6 +-
.../apache/sis/storage/esri/AsciiGridStore.java | 33 +-
.../org/apache/sis/storage/esri/RasterStore.java | 35 +-
.../apache/sis/storage/esri/RawRasterReader.java | 4 +-
.../org/apache/sis/storage/esri/WritableStore.java | 4 +-
.../apache/sis/storage/event/StoreListeners.java | 5 +-
.../apache/sis/storage/image/DataStoreFilter.java | 21 +-
.../sis/storage/image/WorldFileResource.java | 2 +-
.../apache/sis/storage/image/WritableStore.java | 27 +-
.../apache/sis/storage/esri/WritableStoreTest.java | 8 +-
.../org/apache/sis/converter/SystemRegistry.java | 10 +-
.../main/org/apache/sis/measure/AngleFormat.java | 47 +-
.../sis/pending/jdk/{JDK22.java => JDK20.java} | 23 +-
.../main/org/apache/sis/pending/jdk/JDK24.txt | 1 +
.../main/org/apache/sis/setup/Configuration.java | 45 +-
.../apache/sis/setup/InstallationResources.java | 7 +-
.../main/org/apache/sis/system/Reflect.java | 27 +
.../main/org/apache/sis/system/Shutdown.java | 38 +-
.../main/org/apache/sis/util/Version.java | 13 +-
.../org/apache/sis/util/collection/RangeSet.java | 6 +-
.../main/org/apache/sis/util/logging/Logging.java | 5 +-
.../main/org/apache/sis/util/resources/Errors.java | 7 +-
.../apache/sis/util/resources/Errors.properties | 1 -
.../apache/sis/util/resources/Errors_fr.properties | 1 -
.../sis/util/resources/IndexedResourceBundle.java | 19 +
.../apache/sis/storage/geopackage/GpkgStore.java | 2 +-
.../sis/storage/geopackage/GpkgStoreTest.java | 16 +-
.../conformance/CoreConformanceTest.java | 2 +-
.../sis/storage/shapefile/ShapefileStore.java | 2 +-
.../sis/storage/shapefile/dbf/DBFIOTest.java | 2 +-
.../sis/storage/shapefile/shp/ShapeIOTest.java | 2 +-
netbeans-project/ivy.xml | 2 +-
.../apache/sis/gui/coverage/CoverageCanvas.java | 2 +-
.../org/apache/sis/gui/coverage/GridTileCache.java | 11 +-
.../main/org/apache/sis/gui/coverage/GridView.java | 4 +-
.../apache/sis/gui/coverage/IsolineRenderer.java | 2 +-
.../apache/sis/gui/internal/ImageConverter.java | 4 +-
.../apache/sis/gui/internal/io/FileAccessView.java | 2 +-
.../main/org/apache/sis/gui/map/MapCanvasAWT.java | 2 +-
.../sis/gui/metadata/IdentificationInfo.java | 14 +-
.../org/apache/sis/gui/metadata/MetadataTree.java | 15 +-
.../sis/gui/metadata/StandardMetadataTree.java | 8 +-
.../org/apache/sis/gui/metadata/package-info.java | 2 +-
.../main/org/apache/sis/storage/gdal/Band.java | 2 +-
.../apache/sis/storage/gdal/FeatureIterator.java | 2 +-
.../org/apache/sis/storage/gdal/FeatureLayer.java | 76 ++-
.../org/apache/sis/storage/gdal/FieldAccessor.java | 33 +-
.../org/apache/sis/storage/gdal/TiledResource.java | 19 +-
settings.gradle.kts | 3 +-
236 files changed, 5566 insertions(+), 2646 deletions(-)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/coverage/privy/{MultiSourceArgument.java => BandAggregateArgument.java} (98%)
delete mode 100644 endorsed/src/org.apache.sis.feature/main/org/apache/sis/coverage/privy/ImageLayout.java
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/{MultiSourceLayout.java => BandAggregateLayout.java} (70%)
create mode 100644 endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/ImageLayout.java
create mode 100644 endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/ImageOverlay.java
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/BatchComputedImage.java (99%)
create mode 100644 endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/privy/ColorModelBuilder.java
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ColorModelFactory.java (92%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ColorModelType.java (98%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage/privy/ColorModelBuilder.java => image/privy/ColorScaleBuilder.java} (94%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ColorsForRange.java (98%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/DeferredProperty.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/FillValues.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ImageUtilities.java (86%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/MultiBandsIndexColorModel.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ObservableImage.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/RasterFactory.java (98%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage/privy/SampleModelFactory.java => image/privy/SampleModelBuilder.java} (76%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ScaledColorModel.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/ScaledColorSpace.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/TileErrorHandler.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/TileOpExecutor.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/TilePlaceholder.java (98%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/TiledImage.java (99%)
rename endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/WritableTiledImage.java (99%)
copy endorsed/src/org.apache.sis.feature/main/org/apache/sis/{coverage => image}/privy/package-info.java (91%)
rename endorsed/src/org.apache.sis.feature/test/org/apache/sis/{coverage/privy => image}/ImageLayoutTest.java (79%)
create mode 100644 endorsed/src/org.apache.sis.feature/test/org/apache/sis/image/ImageOverlayTest.java
rename endorsed/src/org.apache.sis.feature/test/org/apache/sis/{coverage => image}/privy/ColorModelBuilderTest.java (91%)
rename endorsed/src/org.apache.sis.feature/test/org/apache/sis/{coverage => image}/privy/ImageUtilitiesTest.java (92%)
rename endorsed/src/org.apache.sis.feature/test/org/apache/sis/{coverage/privy/SampleModelFactoryTest.java => image/privy/SampleModelBuilderTest.java} (78%)
rename endorsed/src/org.apache.sis.feature/test/org/apache/sis/{coverage => image}/privy/ScaledColorSpaceTest.java (98%)
create mode 100644 endorsed/src/org.apache.sis.storage.geotiff/test/org/apache/sis/storage/geotiff/GeoTiffStoreTest.java
copy endorsed/src/org.apache.sis.util/main/org/apache/sis/pending/jdk/{JDK22.java => JDK20.java} (62%)
create mode 100644 endorsed/src/org.apache.sis.util/main/org/apache/sis/pending/jdk/JDK24.txt
(sis) 02/03: Merge branch 'geoapi-3.1'
Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/sis.git
commit 4bd7092a20528c1dea8a6094e3bee9ef8c001f69
Merge: 84a6d62055 630a996a08
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Fri Dec 27 12:58:17 2024 +0100
Merge branch 'geoapi-3.1'
.../org.apache.sis.feature/main/module-info.java | 5 +++
.../apache/sis/coverage/grid/DefaultEvaluator.java | 2 +-
.../apache/sis/coverage/grid/GridCoverage2D.java | 4 +--
.../sis/coverage/grid/GridCoverageBuilder.java | 8 ++---
.../apache/sis/coverage/grid/ImageRenderer.java | 12 +++----
.../apache/sis/coverage/grid/SliceGeometry.java | 2 +-
.../apache/sis/coverage/privy/RangeArgument.java | 6 ++--
.../main/org/apache/sis/image/AnnotatedImage.java | 4 +--
.../org/apache/sis/image/BandAggregateImage.java | 2 +-
.../org/apache/sis/image/BandAggregateLayout.java | 4 +--
.../main/org/apache/sis/image/BandSelectImage.java | 8 ++---
.../main/org/apache/sis/image/BandSharing.java | 2 +-
.../apache/sis/image/BandedSampleConverter.java | 8 ++---
.../main/org/apache/sis/image/Colorizer.java | 8 ++---
.../main/org/apache/sis/image/ComputedImage.java | 2 +-
.../main/org/apache/sis/image/DataType.java | 2 +-
.../main/org/apache/sis/image/ImageCombiner.java | 4 +--
.../main/org/apache/sis/image/ImageLayout.java | 2 +-
.../main/org/apache/sis/image/ImageOverlay.java | 2 +-
.../main/org/apache/sis/image/ImageProcessor.java | 4 +--
.../main/org/apache/sis/image/MaskImage.java | 6 ++--
.../main/org/apache/sis/image/MaskedImage.java | 6 ++--
.../org/apache/sis/image/MultiSourceImage.java | 2 +-
.../org/apache/sis/image/MultiSourcePrefetch.java | 2 +-
.../main/org/apache/sis/image/PixelIterator.java | 2 +-
.../main/org/apache/sis/image/PlanarImage.java | 8 ++---
.../sis/image/PositionalConsistencyImage.java | 2 +-
.../main/org/apache/sis/image/PrefetchedImage.java | 8 ++---
.../main/org/apache/sis/image/RecoloredImage.java | 4 +--
.../main/org/apache/sis/image/ResampledImage.java | 6 ++--
.../org/apache/sis/image/SourceAlignedImage.java | 2 +-
.../org/apache/sis/image/StatisticsCalculator.java | 2 +-
.../main/org/apache/sis/image/Transferer.java | 2 +-
.../main/org/apache/sis/image/Visualization.java | 4 +--
.../apache/sis/image/WritableComputedImage.java | 2 +-
.../privy/BatchComputedImage.java | 2 +-
.../privy/ColorModelBuilder.java | 2 +-
.../privy/ColorModelFactory.java | 2 +-
.../{coverage => image}/privy/ColorModelType.java | 2 +-
.../privy/ColorScaleBuilder.java | 2 +-
.../{coverage => image}/privy/ColorsForRange.java | 2 +-
.../privy/DeferredProperty.java | 2 +-
.../sis/{coverage => image}/privy/FillValues.java | 2 +-
.../{coverage => image}/privy/ImageUtilities.java | 2 +-
.../privy/MultiBandsIndexColorModel.java | 2 +-
.../{coverage => image}/privy/ObservableImage.java | 2 +-
.../{coverage => image}/privy/RasterFactory.java | 2 +-
.../privy/SampleModelBuilder.java} | 20 +++++------
.../privy/ScaledColorModel.java | 2 +-
.../privy/ScaledColorSpace.java | 2 +-
.../privy/TileErrorHandler.java | 2 +-
.../{coverage => image}/privy/TileOpExecutor.java | 2 +-
.../{coverage => image}/privy/TilePlaceholder.java | 2 +-
.../sis/{coverage => image}/privy/TiledImage.java | 2 +-
.../privy/WritableTiledImage.java | 2 +-
.../org/apache/sis/image/privy/package-info.java | 30 ++++++++++++++++
.../sis/coverage/grid/GridCoverage2DTest.java | 2 +-
.../coverage/grid/ResampledGridCoverageTest.java | 2 +-
.../coverage/grid/TranslatedGridCoverageTest.java | 2 +-
.../apache/sis/image/BandAggregateImageTest.java | 4 +--
.../org/apache/sis/image/BandSelectImageTest.java | 4 +--
.../org/apache/sis/image/ImageOverlayTest.java | 2 +-
.../org/apache/sis/image/InterpolationTest.java | 2 +-
.../test/org/apache/sis/image/MaskedImageTest.java | 2 +-
.../test/org/apache/sis/image/PlanarImageTest.java | 2 +-
.../org/apache/sis/image/ResampledImageTest.java | 2 +-
.../apache/sis/image/StatisticsCalculatorTest.java | 2 +-
.../test/org/apache/sis/image/TiledImageMock.java | 4 +--
.../privy/ColorModelBuilderTest.java | 2 +-
.../privy/ImageUtilitiesTest.java | 2 +-
.../privy/SampleModelBuilderTest.java} | 42 +++++++++++-----------
.../privy/ScaledColorSpaceTest.java | 2 +-
.../sis/image/processing/isoline/IsolinesTest.java | 2 +-
.../org/apache/sis/map/coverage/RenderingData.java | 4 +--
.../sis/map/coverage/RenderingWorkaround.java | 2 +-
.../sis/storage/geotiff/CompressedSubset.java | 2 +-
.../org/apache/sis/storage/geotiff/DataSubset.java | 6 ++--
.../sis/storage/geotiff/ImageFileDirectory.java | 8 ++---
.../org/apache/sis/storage/geotiff/Writer.java | 2 +-
.../storage/geotiff/writer/ReformattedImage.java | 6 ++--
.../org/apache/sis/storage/geotiff/WriterTest.java | 2 +-
.../apache/sis/storage/netcdf/base/Convention.java | 2 +-
.../sis/storage/netcdf/base/RasterResource.java | 2 +-
.../sis/storage/sql/postgis/RasterReader.java | 6 ++--
.../aggregate/ConcatenatedGridCoverage.java | 2 +-
.../sis/storage/base/TiledDeferredImage.java | 2 +-
.../apache/sis/storage/base/TiledGridCoverage.java | 4 +--
.../apache/sis/storage/base/TiledGridResource.java | 4 +--
.../apache/sis/storage/esri/AsciiGridStore.java | 6 ++--
.../org/apache/sis/storage/esri/RasterStore.java | 8 ++---
.../apache/sis/storage/esri/RawRasterReader.java | 4 +--
.../sis/storage/image/WorldFileResource.java | 2 +-
.../main/org/apache/sis/util/resources/Errors.java | 7 +---
.../apache/sis/util/resources/Errors.properties | 1 -
.../apache/sis/util/resources/Errors_fr.properties | 1 -
.../apache/sis/gui/coverage/CoverageCanvas.java | 2 +-
.../main/org/apache/sis/gui/coverage/GridView.java | 2 +-
.../apache/sis/gui/coverage/IsolineRenderer.java | 2 +-
.../apache/sis/gui/internal/ImageConverter.java | 4 +--
.../main/org/apache/sis/gui/map/MapCanvasAWT.java | 2 +-
.../main/org/apache/sis/storage/gdal/Band.java | 2 +-
.../org/apache/sis/storage/gdal/TiledResource.java | 4 +--
102 files changed, 224 insertions(+), 194 deletions(-)
diff --cc endorsed/src/org.apache.sis.feature/main/module-info.java
index d6907a8a0b,88846fbe09..1b5b4cf258
--- a/endorsed/src/org.apache.sis.feature/main/module-info.java
+++ b/endorsed/src/org.apache.sis.feature/main/module-info.java
@@@ -72,7 -71,16 +72,12 @@@ module org.apache.sis.feature
exports org.apache.sis.geometry.wrapper.j2d to
org.apache.sis.gui; // In the "optional" sub-project.
- exports org.apache.sis.geometry.wrapper.jts to
- org.apache.sis.portrayal.map, // In the "incubator" sub-project.
- org.apache.sis.cql; // In the "incubator" sub-project.
-
exports org.apache.sis.coverage.privy to
+ org.apache.sis.storage,
+ org.apache.sis.storage.netcdf,
+ org.apache.sis.portrayal;
+
+ exports org.apache.sis.image.privy to
org.apache.sis.storage,
org.apache.sis.storage.sql,
org.apache.sis.storage.netcdf,
diff --cc endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/PixelIterator.java
index f9c8ba8df5,cb5bd3c4cd..496f47c258
--- a/endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/PixelIterator.java
+++ b/endorsed/src/org.apache.sis.feature/main/org/apache/sis/image/PixelIterator.java
@@@ -46,9 -46,12 +46,9 @@@ import org.apache.sis.util.resources.Er
import org.apache.sis.measure.NumberRange;
import org.apache.sis.util.privy.Numerics;
import org.apache.sis.feature.internal.Resources;
- import org.apache.sis.coverage.privy.ImageUtilities;
+ import org.apache.sis.image.privy.ImageUtilities;
import static org.apache.sis.pending.jdk.JDK18.ceilDiv;
-// Specific to the geoapi-3.1 and geoapi-4.0 branches:
-import org.opengis.coverage.grid.SequenceType;
-
/**
* An iterator over sample values in a raster or an image. This iterator makes easier to read and write efficiently
diff --cc endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/aggregate/ConcatenatedGridCoverage.java
index ae0591a7bf,46d2ccac74..53c7bcc145
--- a/endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/aggregate/ConcatenatedGridCoverage.java
+++ b/endorsed/src/org.apache.sis.storage/main/org/apache/sis/storage/aggregate/ConcatenatedGridCoverage.java
@@@ -32,10 -32,10 +32,10 @@@ import org.apache.sis.storage.internal.
import org.apache.sis.util.privy.Numerics;
import org.apache.sis.util.collection.Cache;
import org.apache.sis.util.logging.Logging;
- import static org.apache.sis.coverage.privy.ImageUtilities.LOGGER;
+ import static org.apache.sis.image.privy.ImageUtilities.LOGGER;
-// Specific to the geoapi-3.1 and geoapi-4.0 branches:
-import org.opengis.coverage.CannotEvaluateException;
+// Specific to the main branch:
+import org.apache.sis.coverage.CannotEvaluateException;
/**
(sis) 03/03: Merge branch 'geoapi-3.1'
Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/sis.git
commit ae65a8be08ff31fc78d0f346a6b9a2a78380aa8d
Merge: 4bd7092a20 4c5563faad
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Sat Dec 28 17:32:50 2024 +0100
Merge branch 'geoapi-3.1'
.../org/apache/sis/feature/DefaultFeatureType.java | 17 +-
.../sis/feature/builder/FeatureTypeBuilder.java | 14 +-
.../apache/sis/feature/privy/FeatureUtilities.java | 6 +
.../org/apache/sis/image/BandAggregateLayout.java | 8 +-
.../apache/sis/image/BandedSampleConverter.java | 2 +-
.../main/org/apache/sis/image/DataType.java | 268 ++++++++++++++++-----
.../main/org/apache/sis/image/PixelIterator.java | 12 +-
.../main/org/apache/sis/image/ResampledImage.java | 2 +-
.../main/org/apache/sis/image/Transferer.java | 6 +-
.../apache/sis/image/privy/ColorModelBuilder.java | 3 +-
.../apache/sis/image/privy/ColorModelFactory.java | 6 +-
.../apache/sis/image/privy/ColorScaleBuilder.java | 8 +-
.../org/apache/sis/image/privy/ImageUtilities.java | 84 +------
.../org/apache/sis/image/privy/RasterFactory.java | 9 +-
.../apache/sis/image/privy/TilePlaceholder.java | 5 +-
.../test/org/apache/sis/image/DataTypeTest.java | 42 +++-
.../apache/sis/image/privy/ImageUtilitiesTest.java | 16 --
.../apache/sis/metadata/sql/MetadataWriter.java | 8 +-
.../apache/sis/metadata/sql/privy/SQLBuilder.java | 13 +-
.../sis/referencing/factory/sql/EPSGInstaller.java | 22 +-
.../provider/FranceGeocentricInterpolation.java | 18 +-
.../org/apache/sis/storage/geotiff/DataSubset.java | 2 +-
.../sis/storage/geotiff/GeoTiffStoreProvider.java | 57 ++++-
.../sis/storage/geotiff/ImageFileDirectory.java | 2 +-
.../org/apache/sis/storage/geotiff/Writer.java | 4 +-
.../storage/geotiff/inflater/CopyFromBytes.java | 5 +-
.../geotiff/inflater/HorizontalPredictor.java | 5 +-
.../geotiff/writer/HorizontalPredictor.java | 5 +-
.../storage/geotiff/writer/ReformattedImage.java | 5 +-
.../sis/storage/geotiff/writer/TileMatrix.java | 14 +-
.../apache/sis/storage/netcdf/base/DataType.java | 2 +-
.../org/apache/sis/storage/DataStoreProvider.java | 22 +-
.../apache/sis/storage/base/TiledGridResource.java | 2 +-
.../org/apache/sis/storage/esri/RasterStore.java | 8 +-
.../main/org/apache/sis/util/Version.java | 13 +-
.../main/org/apache/sis/gui/coverage/GridView.java | 4 +-
.../apache/sis/storage/gdal/FeatureIterator.java | 2 +-
.../org/apache/sis/storage/gdal/FeatureLayer.java | 76 ++++--
.../org/apache/sis/storage/gdal/FieldAccessor.java | 33 ++-
39 files changed, 494 insertions(+), 336 deletions(-)
diff --cc endorsed/src/org.apache.sis.feature/main/org/apache/sis/feature/DefaultFeatureType.java
index 1ac6a3bc4d,5984c258a3..dbf436cd0d
--- a/endorsed/src/org.apache.sis.feature/main/org/apache/sis/feature/DefaultFeatureType.java
+++ b/endorsed/src/org.apache.sis.feature/main/org/apache/sis/feature/DefaultFeatureType.java
@@@ -396,8 -391,8 +391,8 @@@ public class DefaultFeatureType extend
*
* In the `aliases` map below, null values will be assigned to ambiguous short names.
*/
- final Map<String, AbstractIdentifiedType> aliases = new LinkedHashMap<>();
- final var aliases = new LinkedHashMap<String, PropertyType>();
- for (final PropertyType property : allProperties) {
++ final var aliases = new LinkedHashMap<String, AbstractIdentifiedType>();
+ for (final AbstractIdentifiedType property : allProperties) {
GenericName name = property.getName();
while (name instanceof ScopedName) {
if (name == (name = ((ScopedName) name).tail())) break; // Safety against broken implementations.
diff --cc endorsed/src/org.apache.sis.feature/main/org/apache/sis/feature/builder/FeatureTypeBuilder.java
index b44ee0c7d6,22287ece14..a58a813c62
--- a/endorsed/src/org.apache.sis.feature/main/org/apache/sis/feature/builder/FeatureTypeBuilder.java
+++ b/endorsed/src/org.apache.sis.feature/main/org/apache/sis/feature/builder/FeatureTypeBuilder.java
@@@ -298,13 -298,13 +298,13 @@@ public class FeatureTypeBuilder extend
* For each operation, wrap them in pseudo-builder only if the operation
* is not one of the operations automatically generated by this builder.
*/
- final Map<String,Set<AttributeRole>> propertyRoles = new HashMap<>();
+ final var propertyRoles = new HashMap<String,Set<AttributeRole>>();
- for (final PropertyType property : template.getProperties(false)) {
+ for (final AbstractIdentifiedType property : template.getProperties(false)) {
PropertyTypeBuilder builder;
- if (property instanceof AttributeType<?>) {
- builder = new AttributeTypeBuilder<>(this, (AttributeType<?>) property);
- } else if (property instanceof FeatureAssociationRole) {
- builder = new AssociationRoleBuilder(this, (FeatureAssociationRole) property);
+ if (property instanceof DefaultAttributeType<?>) {
+ builder = new AttributeTypeBuilder<>(this, (DefaultAttributeType<?>) property);
+ } else if (property instanceof DefaultAssociationRole) {
+ builder = new AssociationRoleBuilder(this, (DefaultAssociationRole) property);
} else {
builder = null; // Do not create OperationWrapper now - see below.
}
@@@ -708,9 -699,9 +708,9 @@@
*
* @see #properties()
*/
- public <V> AttributeTypeBuilder<V> addAttribute(final AttributeType<V> template) {
+ public <V> AttributeTypeBuilder<V> addAttribute(final DefaultAttributeType<V> template) {
ensureNonNull("template", template);
- final AttributeTypeBuilder<V> property = new AttributeTypeBuilder<>(this, template);
+ final var property = new AttributeTypeBuilder<V>(this, template);
properties.add(property);
clearCache();
return property;
@@@ -775,9 -762,9 +775,9 @@@
*
* @see #properties()
*/
- public AssociationRoleBuilder addAssociation(final FeatureType type) {
+ public AssociationRoleBuilder addAssociation(final DefaultFeatureType type) {
ensureNonNull("type", type);
- final AssociationRoleBuilder property = new AssociationRoleBuilder(this, type, type.getName());
+ final var property = new AssociationRoleBuilder(this, type, type.getName());
properties.add(property);
clearCache();
return property;
@@@ -816,9 -799,9 +816,9 @@@
*
* @see #properties()
*/
- public AssociationRoleBuilder addAssociation(final FeatureAssociationRole template) {
+ public AssociationRoleBuilder addAssociation(final DefaultAssociationRole template) {
ensureNonNull("template", template);
- final AssociationRoleBuilder property = new AssociationRoleBuilder(this, template);
+ final var property = new AssociationRoleBuilder(this, template);
properties.add(property);
clearCache();
return property;
@@@ -941,7 -918,7 +941,7 @@@
geometryIndex = numSynthetic++;
}
}
- final AbstractIdentifiedType[] propertyTypes = new AbstractIdentifiedType[numSynthetic + numSpecified];
- final var propertyTypes = new PropertyType[numSynthetic + numSpecified];
++ final var propertyTypes = new AbstractIdentifiedType[numSynthetic + numSpecified];
int propertyCursor = numSynthetic;
int identifierCursor = 0;
for (int i=0; i<numSpecified; i++) {
(sis) 01/03: Merge branch 'geoapi-3.1'
Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
desruisseaux pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/sis.git
commit 84a6d62055cda36f8c55ef11694b762bbb02258e
Merge: 1531118a77 9160018564
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Fri Dec 27 11:17:07 2024 +0100
Merge branch 'geoapi-3.1'
.../sis/buildtools/coding/ReorganizeImports.java | 2 +-
.../org/apache/sis/buildtools/book/OGC.lst | 1 +
.../org/apache/sis/cloud/aws/s3/FileService.java | 36 +-
.../main/org/apache/sis/cloud/aws/s3/KeyPath.java | 4 +-
.../apache/sis/cloud/aws/s3/ObjectAttributes.java | 5 +-
.../org/apache/sis/cloud/aws/s3/package-info.java | 31 +-
.../coverage/grid/BandAggregateGridCoverage.java | 10 +-
.../coverage/grid/CoordinateOperationFinder.java | 2 +
.../org/apache/sis/coverage/grid/GridCoverage.java | 5 +-
.../sis/coverage/grid/GridCoverageBuilder.java | 9 +-
.../sis/coverage/grid/GridCoverageProcessor.java | 8 +-
.../apache/sis/coverage/grid/GridDerivation.java | 6 +-
.../org/apache/sis/coverage/grid/GridGeometry.java | 219 ++++--
.../apache/sis/coverage/grid/ImageRenderer.java | 13 +-
...rceArgument.java => BandAggregateArgument.java} | 8 +-
.../sis/coverage/privy/ColorModelBuilder.java | 757 +++++----------------
.../sis/coverage/privy/ColorModelFactory.java | 57 +-
.../apache/sis/coverage/privy/ColorModelType.java | 2 +-
...lorModelBuilder.java => ColorScaleBuilder.java} | 55 +-
.../apache/sis/coverage/privy/ColorsForRange.java | 6 +-
.../org/apache/sis/coverage/privy/ImageLayout.java | 458 -------------
.../apache/sis/coverage/privy/ImageUtilities.java | 47 +-
.../apache/sis/coverage/privy/RasterFactory.java | 2 +-
.../sis/coverage/privy/SampleDimensions.java | 27 +-
.../sis/coverage/privy/SampleModelFactory.java | 75 +-
.../org/apache/sis/feature/internal/Resources.java | 3 +-
.../sis/feature/internal/Resources.properties | 2 +-
.../sis/feature/internal/Resources_fr.properties | 2 +-
.../org/apache/sis/image/BandAggregateImage.java | 125 +++-
...iSourceLayout.java => BandAggregateLayout.java} | 195 +++---
.../main/org/apache/sis/image/BandSelectImage.java | 18 +-
.../apache/sis/image/BandedSampleConverter.java | 45 +-
.../main/org/apache/sis/image/Colorizer.java | 40 +-
.../main/org/apache/sis/image/ComputedImage.java | 23 +-
.../main/org/apache/sis/image/ImageAdapter.java | 4 +-
.../main/org/apache/sis/image/ImageCombiner.java | 32 +-
.../main/org/apache/sis/image/ImageLayout.java | 673 ++++++++++++++++++
.../main/org/apache/sis/image/ImageOverlay.java | 431 ++++++++++++
.../main/org/apache/sis/image/ImageProcessor.java | 227 +++++-
.../org/apache/sis/image/MultiSourceImage.java | 41 +-
.../main/org/apache/sis/image/PlanarImage.java | 71 +-
.../main/org/apache/sis/image/RecoloredImage.java | 63 +-
.../main/org/apache/sis/image/ResampledImage.java | 62 +-
.../org/apache/sis/image/SourceAlignedImage.java | 10 +
.../org/apache/sis/image/StatisticsCalculator.java | 13 +-
.../main/org/apache/sis/image/Transferer.java | 1 -
.../main/org/apache/sis/image/Visualization.java | 78 ++-
.../apache/sis/image/WritableComputedImage.java | 2 +-
.../apache/sis/coverage/grid/GridGeometryTest.java | 15 +-
.../sis/coverage/privy/ColorModelBuilderTest.java | 13 +-
.../sis/coverage/privy/SampleModelFactoryTest.java | 18 +-
.../apache/sis/image/BandAggregateImageTest.java | 66 +-
.../sis/image/BandedSampleConverterTest.java | 17 +-
.../{coverage/privy => image}/ImageLayoutTest.java | 14 +-
.../org/apache/sis/image/ImageOverlayTest.java | 116 ++++
.../org/apache/sis/image/ResampledImageTest.java | 22 +-
.../apache/sis/metadata/iso/extent/Extents.java | 5 +-
.../sis/metadata/privy/ReferencingServices.java | 20 +-
.../apache/sis/metadata/sql/privy/Initializer.java | 7 +-
.../sis/metadata/sql/privy/LocalDataSource.java | 9 +-
.../main/org/apache/sis/xml/MarshallerPool.java | 12 +-
.../apache/sis/xml/bind/IdentifierMapAdapter.java | 16 +-
.../sis/xml/bind/ModifiableIdentifierMap.java | 16 +-
.../org/apache/sis/xml/bind/TypeRegistration.java | 8 +-
.../metadata/replace/ReferenceSystemMetadata.java | 8 +-
.../apache/sis/metadata/PropertyAccessorTest.java | 19 +-
.../org/apache/sis/map/coverage/RenderingData.java | 19 +-
.../main/org/apache/sis/io/wkt/Element.java | 20 +-
.../main/org/apache/sis/io/wkt/Formatter.java | 56 +-
.../apache/sis/referencing/AuthorityFactories.java | 9 +-
.../main/org/apache/sis/referencing/CommonCRS.java | 5 +-
.../sis/referencing/crs/DefaultCompoundCRS.java | 2 +-
.../apache/sis/referencing/cs/AxesConvention.java | 218 +++---
.../factory/ConcurrentAuthorityFactory.java | 4 +-
.../referencing/internal/ServicesForMetadata.java | 20 +-
.../operation/CoordinateOperationFinder.java | 68 +-
.../operation/provider/MapProjection.java | 14 +-
.../transform/AbstractMathTransform2D.java | 31 +-
.../transform/ConcatenatedTransform2D.java | 2 +-
.../transform/ConcatenatedTransformDirect2D.java | 2 +-
.../transform/DefaultMathTransformFactory.java | 12 +-
.../InterpolatedGeocentricTransform2D.java | 4 +-
.../transform/InterpolatedTransform2D.java | 4 +-
.../operation/transform/MolodenskyTransform2D.java | 2 +-
.../transform/PassThroughTransform2D.java | 2 +-
.../operation/transform/ProjectiveTransform2D.java | 2 +-
.../transform/SpecializableTransform2D.java | 4 +-
.../sis/referencing/privy/ShapeUtilities.java | 105 +--
.../operation/CoordinateOperationFinderTest.java | 10 +-
.../referencing/operation/provider/NADCONTest.java | 10 +-
.../referencing/operation/provider/NTv2Test.java | 10 +-
.../sis/referencing/privy/ShapeUtilitiesTest.java | 23 +-
.../referencing/privy/ShapeUtilitiesViewer.java | 10 +-
.../apache/sis/storage/geotiff/FormatModifier.java | 14 +-
.../apache/sis/storage/geotiff/GeoTiffStore.java | 29 +-
.../sis/storage/geotiff/ImageFileDirectory.java | 221 +++---
.../org/apache/sis/storage/geotiff/Writer.java | 153 +++--
.../sis/storage/geotiff/reader/CRSBuilder.java | 68 +-
.../geotiff/reader/GridGeometryBuilder.java | 32 +-
.../sis/storage/geotiff/reader/Localization.java | 1 +
.../sis/storage/geotiff/writer/GeoEncoder.java | 239 ++++---
.../storage/geotiff/writer/ReformattedImage.java | 223 ++++--
.../sis/storage/geotiff/writer/TileMatrix.java | 83 ++-
.../sis/storage/geotiff/GeoTiffStoreTest.java | 111 +++
.../org/apache/sis/storage/geotiff/WriterTest.java | 26 +-
.../apache/sis/storage/netcdf/AttributeNames.java | 30 +
.../apache/sis/storage/netcdf/MetadataReader.java | 28 +-
.../apache/sis/storage/netcdf/base/Convention.java | 13 +-
.../sis/storage/sql/postgis/RasterReader.java | 3 +-
.../sis/storage/xml/stream/StaxStreamReader.java | 10 +-
.../sis/storage/xml/stream/StaxStreamWriter.java | 10 +-
.../apache/sis/io/stream/ChannelDataOutput.java | 28 +
.../org/apache/sis/io/stream/ChannelFactory.java | 46 +-
.../apache/sis/io/stream/HyperRectangleWriter.java | 246 +++++--
.../main/org/apache/sis/io/stream/IOUtilities.java | 16 +
.../main/org/apache/sis/io/stream/Region.java | 30 +
.../org/apache/sis/storage/DataStoreRegistry.java | 47 +-
.../main/org/apache/sis/storage/DataStores.java | 63 +-
.../sis/storage/IncompatibleResourceException.java | 56 +-
.../org/apache/sis/storage/ProbeProviderPair.java | 6 +-
.../main/org/apache/sis/storage/ProbeResult.java | 10 +-
.../org/apache/sis/storage/StorageConnector.java | 15 +-
.../aggregate/BandAggregateGridResource.java | 10 +-
.../apache/sis/storage/base/MetadataBuilder.java | 43 +-
.../apache/sis/storage/base/TiledGridCoverage.java | 8 +-
.../apache/sis/storage/base/TiledGridResource.java | 47 +-
.../sis/storage/base/URIDataStoreProvider.java | 33 +-
.../sis/storage/base/WritableAggregateSupport.java | 2 +-
.../storage/base/WritableGridCoverageSupport.java | 6 +-
.../apache/sis/storage/esri/AsciiGridStore.java | 27 +-
.../org/apache/sis/storage/esri/RasterStore.java | 23 +-
.../org/apache/sis/storage/esri/WritableStore.java | 4 +-
.../apache/sis/storage/event/StoreListeners.java | 5 +-
.../apache/sis/storage/image/DataStoreFilter.java | 21 +-
.../apache/sis/storage/image/WritableStore.java | 27 +-
.../apache/sis/storage/esri/WritableStoreTest.java | 8 +-
.../org/apache/sis/converter/SystemRegistry.java | 10 +-
.../main/org/apache/sis/measure/AngleFormat.java | 47 +-
.../main/org/apache/sis/pending/jdk/JDK20.java} | 45 +-
.../main/org/apache/sis/pending/jdk/JDK24.txt | 1 +
.../main/org/apache/sis/setup/Configuration.java | 45 +-
.../apache/sis/setup/InstallationResources.java | 7 +-
.../main/org/apache/sis/system/Reflect.java | 27 +
.../main/org/apache/sis/system/Shutdown.java | 38 +-
.../org/apache/sis/util/collection/RangeSet.java | 6 +-
.../main/org/apache/sis/util/logging/Logging.java | 5 +-
.../sis/util/resources/IndexedResourceBundle.java | 19 +
.../apache/sis/storage/geopackage/GpkgStore.java | 2 +-
.../sis/storage/geopackage/GpkgStoreTest.java | 16 +-
.../conformance/CoreConformanceTest.java | 2 +-
.../sis/storage/shapefile/ShapefileStore.java | 2 +-
.../sis/storage/shapefile/dbf/DBFIOTest.java | 2 +-
.../sis/storage/shapefile/shp/ShapeIOTest.java | 2 +-
netbeans-project/ivy.xml | 2 +-
.../org/apache/sis/gui/coverage/GridTileCache.java | 11 +-
.../apache/sis/gui/internal/io/FileAccessView.java | 2 +-
.../sis/gui/metadata/IdentificationInfo.java | 14 +-
.../org/apache/sis/gui/metadata/MetadataTree.java | 15 +-
.../sis/gui/metadata/StandardMetadataTree.java | 8 +-
.../org/apache/sis/gui/metadata/package-info.java | 2 +-
.../org/apache/sis/storage/gdal/TiledResource.java | 17 +-
settings.gradle.kts | 3 +-
162 files changed, 4794 insertions(+), 2752 deletions(-)
diff --cc endorsed/src/org.apache.sis.feature/main/org/apache/sis/coverage/grid/GridGeometry.java
index 5a8e234a3b,642cac49b9..0b9510a46a
--- a/endorsed/src/org.apache.sis.feature/main/org/apache/sis/coverage/grid/GridGeometry.java
+++ b/endorsed/src/org.apache.sis.feature/main/org/apache/sis/coverage/grid/GridGeometry.java
@@@ -1143,6 -1162,46 +1162,46 @@@ public class GridGeometry implements Le
return times;
}
+ /**
+ * Returns the "real world" coordinates of the cell at indices (0, 0, … 0).
+ * The returned coordinates map the {@linkplain PixelInCell#CELL_CORNER cell corner}.
+ * This method computes the origin from the "grid to CRS" transform if available.
+ * If that transform is not available, then the minimal coordinate values of the
+ * {@linkplain #getEnvelope() envelope} are returned.
+ *
+ * @return the "real world" coordinates of the cell at indices (0, 0, … 0).
+ * @throws IncompleteGridGeometryException if this grid geometry has no origin —
+ * i.e. <code>{@linkplain #isDefined(int) isDefined}({@linkplain #ORIGIN})</code> returned {@code false}.
+ *
+ * @since 1.5
+ */
+ public double[] getOrigin() {
+ if (cornerToCRS == null) {
+ if (isEnvelopeUndefined()) {
+ throw incomplete(ORIGIN, Resources.Keys.UnspecifiedTransform);
+ }
- return getEnvelope().getLowerCorner().getCoordinates();
++ return getEnvelope().getLowerCorner().getCoordinate();
+ }
+ final double[] origin = new double[cornerToCRS.getTargetDimensions()];
+ final Matrix matrix = MathTransforms.getMatrix(cornerToCRS);
+ if (matrix != null) {
+ final int lastColumn = matrix.getNumCol() - 1;
+ for (int j=0; j < origin.length; j++) {
+ if (Double.isNaN(origin[j] = matrix.getElement(j, lastColumn))) {
+ final Matrix other = MathTransforms.getMatrix(gridToCRS);
+ if (other != null) {
+ origin[j] = other.getElement(j, lastColumn);
+ }
+ }
+ }
+ } else try {
+ cornerToCRS.transform(new double[cornerToCRS.getSourceDimensions()], 0, origin, 0, 1);
+ } catch (TransformException e) {
+ throw new IllegalGridGeometryException(e, "gridToCRS");
+ }
+ return origin;
+ }
+
/**
* Returns an <em>estimation</em> of the grid resolution, in units of the coordinate reference system axes.
* The length of the returned array is the number of CRS dimensions, with {@code resolution[0]}
diff --cc endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/iso/extent/Extents.java
index 82a111d6e9,50475c36c8..b425ce2b84
--- 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
@@@ -420,8 -418,8 +421,8 @@@ public final class Extents extends Stat
@OptionalCandidate
public static MeasurementRange<Double> getVerticalRange(final Extent extent) {
MeasurementRange<Double> range = null;
- RealizationMethod selectedMethod = null;
+ VerticalDatumType selectedMethod = null;
- if (extent != null) {
+ if (extent != null) try {
for (final VerticalExtent element : nonNull(extent.getVerticalElements())) {
double min = element.getMinimumValue();
double max = element.getMaximumValue();
diff --cc endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/privy/ReferencingServices.java
index 09d3707343,78a54e6313..0cff418984
--- a/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/privy/ReferencingServices.java
+++ b/endorsed/src/org.apache.sis.metadata/main/org/apache/sis/metadata/privy/ReferencingServices.java
@@@ -246,22 -243,12 +246,22 @@@ public class ReferencingServices extend
- ///////////////////////////////////////////////////////////////////////////////////////
- //// ////
- //// OTHER REFERENCING SERVICES ////
- //// ////
- ///////////////////////////////////////////////////////////////////////////////////////
+ // ╔═════════════════════════════════════════════════════════════════════════════╗
+ // ║ ║
+ // ║ OTHER REFERENCING SERVICES ║
+ // ║ ║
+ // ╚═════════════════════════════════════════════════════════════════════════════╝
+ /**
+ * Returns the name of the type of values.
+ *
+ * @param parameter parameter for which to get the name of type of values, or {@code null}.
+ * @return name of type of values, or {@code null} if not supported by given implementation.
+ */
+ public TypeName getValueType(ParameterDescriptor<?> parameter) {
+ return null;
+ }
+
/**
* Returns a fully implemented parameter descriptor.
*
diff --cc endorsed/src/org.apache.sis.metadata/main/org/apache/sis/xml/bind/metadata/replace/ReferenceSystemMetadata.java
index f3060452fc,570aadf213..885397ce3c
--- 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
@@@ -42,9 -46,6 +42,9 @@@ import org.opengis.referencing.Referenc
* ├─mrs:referenceSystemIdentifier : mcc:MD_Identifier
* └─mrs:referenceSystemType : mrs:MD_ReferenceSystemTypeCode</pre>
*
- * The {@code referenceSystemType} attribute is currently missing.
++ * The {@code referenceSystemType} attribute is missing. It is present in GeoAPI 3.1 only.
+ * See <a href="https://issues.apache.org/jira/browse/SIS-470">SIS-470</a>.
+ *
* <p>Note that this implementation is very simple and serves no other purpose than being
* a container for XML parsing or formatting. For real referencing service, consider using
* {@link org.apache.sis.referencing.AbstractReferenceSystem} subclasses instead.</p>
@@@ -56,7 -57,10 +56,9 @@@
* @see org.apache.sis.referencing.AbstractReferenceSystem
* @see <a href="https://issues.apache.org/jira/browse/SIS-431">SIS-431</a>
*/
- @XmlType(name = "MD_ReferenceSystem_Type", namespace = Namespaces.MRS)
+ @XmlType(name = "MD_ReferenceSystem_Type", namespace = Namespaces.MRS, propOrder = {
- "name",
- "referenceSystemType"
++ "name"
+ })
@XmlRootElement(name = "MD_ReferenceSystem", namespace = Namespaces.MRS)
public class ReferenceSystemMetadata extends SimpleIdentifiedObject implements ReferenceSystem {
/**
@@@ -138,12 -150,14 +140,12 @@@
@Override
public boolean equals(final Object object, final ComparisonMode mode) {
if (super.equals(object, mode) && (object instanceof ReferenceSystem)) {
- final ReferenceSystem that = (ReferenceSystem) object;
+ final var that = (ReferenceSystem) object;
- if (that.getReferenceSystemType().orElse(null) == referenceSystemType) {
- if (mode.isIgnoringMetadata()) {
- // Compare the name because it was ignored by super.equals(…) in "ignore metadata" mode.
- return Utilities.deepEquals(getName(), that.getName(), mode);
- }
- return Containers.isNullOrEmpty(that.getDomains());
+ if (mode.isIgnoringMetadata()) {
+ // 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 false;
}
diff --cc endorsed/src/org.apache.sis.metadata/test/org/apache/sis/metadata/PropertyAccessorTest.java
index ba13d1028c,1f38589d85..627dc3ae81
--- a/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/metadata/PropertyAccessorTest.java
+++ b/endorsed/src/org.apache.sis.metadata/test/org/apache/sis/metadata/PropertyAccessorTest.java
@@@ -38,6 -38,8 +38,7 @@@ import org.opengis.metadata.identificat
import org.opengis.metadata.maintenance.MaintenanceInformation;
import org.opengis.metadata.spatial.SpatialRepresentationType;
import org.opengis.referencing.IdentifiedObject;
+ import org.opengis.referencing.ReferenceSystem;
-import org.opengis.referencing.ReferenceSystemType;
import org.opengis.referencing.crs.GeodeticCRS;
import org.opengis.referencing.crs.GeographicCRS;
import org.opengis.referencing.datum.GeodeticDatum;
@@@ -241,15 -243,16 +242,15 @@@ public final class PropertyAccessorTes
@Test
public void testConstructorWithCovariantReturnType() {
assertMappingEquals(new PropertyAccessor(GeographicCRS.class, GeographicCRSMock.class, GeographicCRSMock.class),
- //……Declaring type……………………………Method……………………………………………JavaBeans……………………………UML identifier……………………Sentence………………………………Type…………………………………………………………
- GeographicCRS.class, "getCoordinateSystem", "coordinateSystem", "coordinateSystem", "Coordinate system", EllipsoidalCS.class, // Covariant return type
- GeodeticCRS.class, "getDatum", "datum", "datum", "Datum", GeodeticDatum.class, // Covariant return type
- IdentifiedObject.class, "getName", "name", "name", "Name", ReferenceIdentifier.class,
- IdentifiedObject.class, "getAlias", "alias", "alias", "Alias", GenericName[].class,
- IdentifiedObject.class, "getIdentifiers", "identifiers", "identifier", "Identifiers", ReferenceIdentifier[].class,
- ReferenceSystem.class, "getScope", "scope", "SC_CRS.scope", "Scope", InternationalString.class,
- ReferenceSystem.class, "getDomainOfValidity", "domainOfValidity", "domainOfValidity", "Domain of validity", Extent.class,
- IdentifiedObject.class, "getRemarks", "remarks", "remarks", "Remarks", InternationalString.class);
+ //……Declaring type……………………………Method……………………………………………………JavaBeans……………………………………UML identifier………………………Sentence…………………………………………Type…………………………………………………………
+ GeographicCRS.class, "getCoordinateSystem", "coordinateSystem", "coordinateSystem", "Coordinate system", EllipsoidalCS.class, // Covariant return type
+ GeodeticCRS.class, "getDatum", "datum", "datum", "Datum", GeodeticDatum.class, // Covariant return type
- GeodeticCRS.class, "getDatumEnsemble", "datumEnsemble", "datumEnsemble", "Datum ensemble", DatumEnsemble.class, // Covariant return type
+ IdentifiedObject.class, "getName", "name", "name", "Name", ReferenceIdentifier.class,
+ IdentifiedObject.class, "getAlias", "alias", "alias", "Alias", GenericName[].class,
+ IdentifiedObject.class, "getIdentifiers", "identifiers", "identifier", "Identifiers", ReferenceIdentifier[].class,
- IdentifiedObject.class, "getDomains", "domains", "ObjectUsage.domain", "Domains", ObjectDomain[].class,
- IdentifiedObject.class, "getRemarks", "remarks", "remarks", "Remarks", InternationalString.class,
- ReferenceSystem.class, "getReferenceSystemType", "referenceSystemType", "referenceSystemType", "Reference system type", ReferenceSystemType.class);
++ ReferenceSystem.class, "getScope", "scope", "SC_CRS.scope", "Scope", InternationalString.class,
++ ReferenceSystem.class, "getDomainOfValidity", "domainOfValidity", "domainOfValidity", "Domain of validity", Extent.class,
++ IdentifiedObject.class, "getRemarks", "remarks", "remarks", "Remarks", InternationalString.class);
}
/**
diff --cc endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/internal/ServicesForMetadata.java
index 36e58e702e,8c6fc20090..15366f34aa
--- a/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/internal/ServicesForMetadata.java
+++ b/endorsed/src/org.apache.sis.referencing/main/org/apache/sis/referencing/internal/ServicesForMetadata.java
@@@ -455,21 -443,12 +455,21 @@@ public final class ServicesForMetadata
- ///////////////////////////////////////////////////////////////////////////////////////
- //// ////
- //// OTHER REFERENCING SERVICES ////
- //// ////
- ///////////////////////////////////////////////////////////////////////////////////////
+ // ╔═════════════════════════════════════════════════════════════════════════════╗
+ // ║ ║
+ // ║ OTHER REFERENCING SERVICES ║
+ // ║ ║
+ // ╚═════════════════════════════════════════════════════════════════════════════╝
+ /**
+ * Returns the name of the type of values.
+ */
+ @Override
+ public TypeName getValueType(final ParameterDescriptor<?> parameter) {
+ return (parameter instanceof DefaultParameterDescriptor<?>)
+ ? ((DefaultParameterDescriptor<?>) parameter).getValueType() : null;
+ }
+
/**
* Returns a fully implemented parameter descriptor.
*
diff --cc endorsed/src/org.apache.sis.storage.geotiff/main/org/apache/sis/storage/geotiff/Writer.java
index 3de9db2926,6801c886f5..2017108c25
--- a/endorsed/src/org.apache.sis.storage.geotiff/main/org/apache/sis/storage/geotiff/Writer.java
+++ b/endorsed/src/org.apache.sis.storage.geotiff/main/org/apache/sis/storage/geotiff/Writer.java
@@@ -52,10 -60,9 +60,9 @@@ import org.apache.sis.util.ArraysExt
import org.apache.sis.util.privy.Numerics;
import org.apache.sis.util.resources.Errors;
import org.apache.sis.math.Fraction;
- import org.apache.sis.storage.geotiff.writer.TagValue;
- import org.apache.sis.storage.geotiff.writer.TileMatrix;
- import org.apache.sis.storage.geotiff.writer.GeoEncoder;
- import org.apache.sis.storage.geotiff.writer.ReformattedImage;
+
-// Specific to the geoapi-3.1 and geoapi-4.0 branches:
-import org.opengis.coverage.CannotEvaluateException;
++// Specific to the main branch:
++import org.apache.sis.coverage.CannotEvaluateException;
/**
diff --cc endorsed/src/org.apache.sis.storage.geotiff/test/org/apache/sis/storage/geotiff/GeoTiffStoreTest.java
index 0000000000,feb90f7f13..15b063899a
mode 000000,100644..100644
--- a/endorsed/src/org.apache.sis.storage.geotiff/test/org/apache/sis/storage/geotiff/GeoTiffStoreTest.java
+++ b/endorsed/src/org.apache.sis.storage.geotiff/test/org/apache/sis/storage/geotiff/GeoTiffStoreTest.java
@@@ -1,0 -1,111 +1,111 @@@
+ /*
+ * 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.storage.geotiff;
+
+ import java.nio.file.Path;
+ import java.nio.file.Files;
+ import java.awt.image.BufferedImage;
+ import java.awt.image.RenderedImage;
+ import org.opengis.referencing.cs.AxisDirection;
+ import org.apache.sis.storage.DataStore;
+ import org.apache.sis.storage.DataStores;
+ import org.apache.sis.storage.StorageConnector;
+ import org.apache.sis.storage.GridCoverageResource;
+ import org.apache.sis.coverage.grid.GridExtent;
+ import org.apache.sis.coverage.grid.GridGeometry;
+ import org.apache.sis.coverage.grid.PixelInCell;
+ import org.apache.sis.coverage.grid.GridCoverage;
+ import org.apache.sis.coverage.grid.GridCoverageBuilder;
+ import org.apache.sis.referencing.operation.transform.MathTransforms;
+ import org.apache.sis.referencing.operation.matrix.Matrix4;
+ import org.apache.sis.referencing.CRS;
+
+ // Test dependencies
+ import org.junit.jupiter.api.Test;
+ import static org.junit.jupiter.api.Assertions.*;
+ import org.apache.sis.test.TestCase;
+ import org.apache.sis.test.TestUtilities;
+ import org.apache.sis.referencing.crs.HardCodedCRS;
+
-// Specific to the geoapi-3.1 and geoapi-4.0 branches:
-import static org.opengis.test.Assertions.assertMatrixEquals;
-import static org.opengis.test.Assertions.assertAxisDirectionsEqual;
++// Specific to the main branch:
++import static org.apache.sis.test.GeoapiAssert.assertMatrixEquals;
++import static org.apache.sis.test.GeoapiAssert.assertAxisDirectionsEqual;
+
+
+ /**
+ * integration tests for {@link GeoTiffStore}.
+ *
+ * @author Martin Desruisseaux (Geomatys)
+ */
+ public final class GeoTiffStoreTest extends TestCase {
+ /**
+ * Creates a new test case.
+ */
+ public GeoTiffStoreTest() {
+ }
+
+ /**
+ * Tests writing an image with a non-linear vertical component in the "grid to CRS" transform.
+ * This method merely tests that no exception is thrown during the execution, and that reading
+ * the image back can give back the three-dimensional <abbr>CRS</abbr>.
+ *
+ * @throws Exception if an error occurred while preparing or running the test.
+ */
+ @Test
+ public void testNonLinearVerticalTransform() throws Exception {
+ final int width = 5;
+ final int height = 4;
+ final var builder = new GridCoverageBuilder();
+ final var extent = new GridExtent(null, null, new long[] {width, height, 1}, false);
+ final var crs = CRS.compound(HardCodedCRS.WGS84_LATITUDE_FIRST, HardCodedCRS.DEPTH);
+ final var gridToCRS = MathTransforms.compound(
+ MathTransforms.scale(0.25, -0.25),
+ MathTransforms.interpolate(new double[] {0, 1, 2}, new double[] {3, 4, 9}));
+ builder.setDomain(new GridGeometry(extent, PixelInCell.CELL_CORNER, gridToCRS, crs));
+ builder.setValues(new BufferedImage(width, height, BufferedImage.TYPE_INT_ARGB));
+ final GridCoverage coverage = builder.build();
+ final Path file = Files.createTempFile("sis-test-", ".tiff");
+ try {
+ try (DataStore store = DataStores.openWritable(new StorageConnector(file), "GeoTIFF")) {
+ assertInstanceOf(GeoTiffStore.class, store).append(coverage, null);
+ }
+ /*
+ * Read the image that we wrote in above block. This block merely tests that no exception is thrown,
+ * and that the result has the expected number of dimensions, axis order and scale factors.
+ */
+ try (DataStore store = DataStores.open(new StorageConnector(file), "GeoTIFF")) {
+ GridCoverageResource r = TestUtilities.getSingleton(assertInstanceOf(GeoTiffStore.class, store).components());
+ GridGeometry gg = r.getGridGeometry();
+ assertEquals(3, gg.getDimension());
+ assertAxisDirectionsEqual(gg.getCoordinateReferenceSystem().getCoordinateSystem(),
+ AxisDirection.EAST, AxisDirection.NORTH, AxisDirection.DOWN);
+
+ assertMatrixEquals(new Matrix4(0, -0.25, 0, 0,
+ 0.25, 0, 0, 0,
+ 0, 0, 1, 3,
+ 0, 0, 0, 1),
+ MathTransforms.getMatrix(gg.getGridToCRS(PixelInCell.CELL_CORNER)), 0, "gridToCRS");
+
+ RenderedImage image = r.read(null).render(null);
+ assertEquals(width, image.getWidth(), "width");
+ assertEquals(height, image.getHeight(), "height");
+ }
+ } finally {
+ Files.delete(file);
+ }
+ }
+ }
diff --cc optional/src/org.apache.sis.gui/main/org/apache/sis/gui/metadata/IdentificationInfo.java
index b9bfdec7f2,546974e84b..13e8f60ab0
--- a/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/metadata/IdentificationInfo.java
+++ b/optional/src/org.apache.sis.gui/main/org/apache/sis/gui/metadata/IdentificationInfo.java
@@@ -59,10 -61,8 +61,11 @@@ import org.apache.sis.util.logging.Logg
import org.apache.sis.util.collection.BackingStoreException;
import org.apache.sis.util.resources.Vocabulary;
import static org.apache.sis.util.privy.CollectionsExt.nonNull;
+ import static org.apache.sis.gui.internal.LogHandler.LOGGER;
+// Specific to the main branch:
+import org.opengis.metadata.identification.DataIdentification;
+
/**
* The pane where to show the values of {@link Identification} objects.