Interface WritableGridCoverageResource
- All Superinterfaces:
DataSet, GridCoverageResource, Resource
A
GridCoverageResource with writing capabilities. WritableGridCoverageResource inherits the reading
capabilities from its parent and adds a write operation. Some aspects of the write operation can
be controlled by options, which may be DataStore-specific.- Since:
- 1.2
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumWrite options that may apply to any data store.static interfaceConfiguration of the process of writing a coverage in a data store.Nested classes/interfaces inherited from interface Resource
Resource.FileSetModifier and TypeInterfaceDescriptionstatic classPaths to the files potentially used by the enclosing resource. -
Method Summary
Modifier and TypeMethodDescriptionvoidwrite(GridCoverage coverage, WritableGridCoverageResource.Option... options) Writes a new coverage in the data store for this resource.Methods inherited from interface GridCoverageResource
getAvailableResolutions, getEnvelope, getGridGeometry, getLoadingStrategy, getResolutions, getSampleDimensions, read, setLoadingStrategy, subsetModifier and TypeMethodDescriptiondefault List<double[]> Returns the preferred resolutions (in units of CRS axes) for read operations in this data store.Returns the spatiotemporal extent of this resource in its most natural coordinate reference system.Returns the valid extent of grid coordinates together with the conversion from those grid coordinates to real world coordinates.default RasterLoadingStrategyReturns an indication about when the "physical" loading of raster data will happen.default List<double[]> Deprecated, for removal: This API element is subject to removal in a future version.Returns the ranges of sample values together with the conversion from samples to real values.read(GridGeometry domain, int... ranges) Loads a subset of the grid coverage represented by this resource.default booleansetLoadingStrategy(RasterLoadingStrategy strategy) Sets the preferred strategy about when to do the "physical" loading of raster data.default GridCoverageResourceRequests a subset of the coverage.Methods inherited from interface Resource
addListener, getFileSet, getIdentifier, getMetadata, removeListenerModifier and TypeMethodDescriptiondefault <T extends StoreEvent>
voidaddListener(Class<T> eventType, StoreListener<? super T> listener) Registers a listener to notify when the specified kind of event occurs in this resource or in children.default Optional<Resource.FileSet> Gets the paths to the files potentially used by this resource.default Optional<GenericName> Returns the resource persistent identifier.Returns information about this resource.default <T extends StoreEvent>
voidremoveListener(Class<T> eventType, StoreListener<? super T> listener) Unregisters a listener previously added to this resource for the given type of events.
-
Method Details
-
write
void write(GridCoverage coverage, WritableGridCoverageResource.Option... options) throws DataStoreException Writes a new coverage in the data store for this resource. If a coverage already exists for this resource, then the behavior of this method is determined by the given options. If no option is specified, the default behavior is to fail if writing a coverage would cause an existing coverage to be overwritten. This behavior can be modified by requesting thereplacementor update of existing coverages.- Parameters:
coverage- new data to write in the data store for this resource.options- configuration of the write operation. May beDataStore-specific options (e.g. for compression, encryption, etc).- Throws:
IllegalArgumentException- if mutually exclusive options are specified.ReadOnlyStorageException- if the resource is (possibly temporarily) read-only.ResourceAlreadyExistsException- if a coverage already exists in this resource and noREPLACEorUPDATEoption have been specified.IncompatibleResourceException- if the given resource cannot be written, for example because its grid geometry is unsupported by this resource.DataStoreException- if another error occurred while writing data in the underlying data store.
-
GridCoverageResource.getAvailableResolutions()but with opposite order.