Package noaa.coastwatch.util.chunk
Class GridChunkProducer
java.lang.Object
noaa.coastwatch.util.chunk.GridChunkProducer
- All Implemented Interfaces:
ChunkProducer
The
GridChunkProducer class provides data chunks from
a Grid object. The chunks produced will
be of an appropriate type for the grid primitive data, created using a
DataChunkFactory instance.- Since:
- 3.4.0
- Author:
- Peter Hollemans
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected GridThe grid to use as a source of data.protected PackingSchemeThe packing scheme for new chunks.protected ScalingSchemeThe scaling scheme for new chunks.protected ChunkingSchemeThe chunking scheme used or null for none. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetChunk(ChunkPosition pos) Produces a data chunk.Gets the external type of chunks produced by this producer.getGrid()Gets the grid used to produce data chunks for this producer.Gets the native chunking scheme for chunks obtained from this producer.Gets a prototype chunk for this producer.
-
Field Details
-
grid
The grid to use as a source of data. -
packing
The packing scheme for new chunks. -
scaling
The scaling scheme for new chunks. -
scheme
The chunking scheme used or null for none.
-
-
Constructor Details
-
GridChunkProducer
Creates a new producer.- Parameters:
grid- the grid to use for chunk data.
-
-
Method Details
-
getGrid
Gets the grid used to produce data chunks for this producer.- Returns:
- the grid for this producer.
-
getExternalType
Description copied from interface:ChunkProducerGets the external type of chunks produced by this producer.- Specified by:
getExternalTypein interfaceChunkProducer- Returns:
- the external data type.
- See Also:
-
getChunk
Description copied from interface:ChunkProducerProduces a data chunk.- Specified by:
getChunkin interfaceChunkProducer- Parameters:
pos- the position of the data chunk to produce.- Returns:
- the data chunk.
-
getNativeScheme
Description copied from interface:ChunkProducerGets the native chunking scheme for chunks obtained from this producer. Calls toChunkProducer.getChunk(noaa.coastwatch.util.chunk.ChunkPosition)are optimized to use chunk positions obtained from the native scheme.- Specified by:
getNativeSchemein interfaceChunkProducer- Returns:
- the native chunking scheme used by this producer, or null if no native chunking scheme is used.
-
getPrototypeChunk
Description copied from interface:ChunkProducerGets a prototype chunk for this producer. Chunks received from theChunkProducer.getChunk(noaa.coastwatch.util.chunk.ChunkPosition)method conform to the prototype.- Specified by:
getPrototypeChunkin interfaceChunkProducer- Returns:
- a prototype chunk for chunks produced by this producer.
-