Package org.geotools.coverage.io.impl
Class DefaultCoverageSource
- Object
-
- DefaultCoverageSource
-
- All Implemented Interfaces:
CoverageSource
- Direct Known Subclasses:
NetCDFSource
public abstract class DefaultCoverageSource extends Object implements CoverageSource
Default implementation ofCoverageSource
.- Author:
- Daniele Romagnoli, GeoSolutions SAS
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface CoverageSource
CoverageSource.AdditionalDomain, CoverageSource.DomainType, CoverageSource.SpatialDomain, CoverageSource.TemporalDomain, CoverageSource.VerticalDomain
-
-
Field Summary
Fields Modifier and Type Field Description protected static EnumSet<CoverageCapabilities>
CAPABILITIES
protected CoverageSourceDescriptor
coverageDescriptor
protected Name
name
-
Constructor Summary
Constructors Modifier Constructor Description protected
DefaultCoverageSource(Name name, CoverageSourceDescriptor descriptor)
-
Method Summary
-
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface CoverageSource
read
-
-
-
-
Field Detail
-
CAPABILITIES
protected static final EnumSet<CoverageCapabilities> CAPABILITIES
-
name
protected final Name name
-
coverageDescriptor
protected final CoverageSourceDescriptor coverageDescriptor
-
-
Constructor Detail
-
DefaultCoverageSource
protected DefaultCoverageSource(Name name, CoverageSourceDescriptor descriptor)
-
-
Method Detail
-
getReadParameterInfo
public Map<String,Parameter<?>> getReadParameterInfo()
Description copied from interface:CoverageSource
Describes the required (and optional) parameters that can be passed to theCoverageSource.read(CoverageReadRequest, ProgressListener)
method.- Specified by:
getReadParameterInfo
in interfaceCoverageSource
- Returns:
- Param a
Map
describing theMap
forCoverageSource.read(CoverageReadRequest, ProgressListener)
.
-
getMetadata
public MetadataNode getMetadata(String metadataDomain, ProgressListener listener)
- Specified by:
getMetadata
in interfaceCoverageSource
-
getMetadataDomains
public Set<Name> getMetadataDomains()
- Specified by:
getMetadataDomains
in interfaceCoverageSource
-
getOverviewsLayouts
public List<? extends RasterLayout> getOverviewsLayouts(ProgressListener listener) throws IOException
- Specified by:
getOverviewsLayouts
in interfaceCoverageSource
- Throws:
IOException
-
getOverviewsNumber
public int getOverviewsNumber(ProgressListener listener) throws IOException
- Specified by:
getOverviewsNumber
in interfaceCoverageSource
- Throws:
IOException
-
getName
public Name getName(ProgressListener listener)
Description copied from interface:CoverageSource
Name of the Coverage (ie data product) provided by this CoverageSource.- Specified by:
getName
in interfaceCoverageSource
- Returns:
- Name of the Coverage (ie data product) provided.
-
ensureNotDisposed
protected void ensureNotDisposed()
-
getCapabilities
public EnumSet<CoverageCapabilities> getCapabilities()
Description copied from interface:CoverageSource
Set of supportedCoverageCapabilities
which can be used to discover capabilities of a certainCoverageSource
.You can use set membership to quickly test abilities:
if( getCapabilities().contains( CoverageCapabilities.READ_SUBSAMPLING ) ){ ... }
- Specified by:
getCapabilities
in interfaceCoverageSource
- Returns:
- a
EnumSet
of CoverageCapabilities which can be used to discover capabilities of thisCoverageSource
.
-
getRangeType
public RangeType getRangeType(ProgressListener listener) throws IOException
Description copied from interface:CoverageSource
Retrieves aRangeType
instance which can be used to describe the codomain for the underlying coverage.- Specified by:
getRangeType
in interfaceCoverageSource
- Returns:
- a
RangeType
instance which can be used to describe the codomain for the underlying coverage. - Throws:
IOException
- in case something bad occurs
-
getCoordinateReferenceSystem
public CoordinateReferenceSystem getCoordinateReferenceSystem()
- Specified by:
getCoordinateReferenceSystem
in interfaceCoverageSource
-
getSpatialDomain
public CoverageSource.SpatialDomain getSpatialDomain() throws IOException
- Specified by:
getSpatialDomain
in interfaceCoverageSource
- Throws:
IOException
-
getTemporalDomain
public CoverageSource.TemporalDomain getTemporalDomain() throws IOException
- Specified by:
getTemporalDomain
in interfaceCoverageSource
- Throws:
IOException
-
getVerticalDomain
public CoverageSource.VerticalDomain getVerticalDomain() throws IOException
- Specified by:
getVerticalDomain
in interfaceCoverageSource
- Throws:
IOException
-
getAdditionalDomains
public List<CoverageSource.AdditionalDomain> getAdditionalDomains() throws IOException
- Specified by:
getAdditionalDomains
in interfaceCoverageSource
- Throws:
IOException
-
getDimensionDescriptors
public List<DimensionDescriptor> getDimensionDescriptors() throws IOException
- Specified by:
getDimensionDescriptors
in interfaceCoverageSource
- Throws:
IOException
-
getInfo
public ResourceInfo getInfo(ProgressListener listener)
Description copied from interface:CoverageSource
Information describing the contents of this resource.Please note that for FeatureContent:
- name - unique with in the context of a Service
- schema - used to identify the type of resource; usually the format or data product
being represented
- Specified by:
getInfo
in interfaceCoverageSource
-
dispose
public void dispose()
Description copied from interface:CoverageSource
Closes thisCoverageSource
and releases any lock or cached information it holds.Once a
CoverageAccess
has been disposed it can be seen as being in unspecified state, hence calling a method on it may have unpredictable results.- Specified by:
dispose
in interfaceCoverageSource
-
-