Package ucar.nc2.internal.iosp.hdf5
Class H5tiledLayoutBB
- java.lang.Object
-
- ucar.nc2.internal.iosp.hdf5.H5tiledLayoutBB
-
public class H5tiledLayoutBB extends Object implements LayoutBB
Iterator to read/write subsets of an array. This calculates byte offsets for HD5 chunked datasets. Assumes that the data is stored in chunks, indexed by a Btree. Used for filtered data Had to split from old H5tiledLayoutBB because need to use H5headerNew.Vinfo.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface ucar.nc2.iosp.LayoutBB
LayoutBB.Chunk
-
-
Field Summary
Fields Modifier and Type Field Description static boolean
debugFilter
-
Constructor Summary
Constructors Constructor Description H5tiledLayoutBB(Variable v2, Section wantSection, RandomAccessFile raf, ucar.nc2.internal.iosp.hdf5.H5objects.Filter[] filterProps, ByteOrder byteOrder)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getElemSize()
Get size of each element in bytes.long
getTotalNelems()
Get total number of elements in the wanted subset.boolean
hasNext()
Is there more to doLayoutBB.Chunk
next()
Get the next chunkString
toString()
-
-
-
Constructor Detail
-
H5tiledLayoutBB
public H5tiledLayoutBB(Variable v2, Section wantSection, RandomAccessFile raf, ucar.nc2.internal.iosp.hdf5.H5objects.Filter[] filterProps, ByteOrder byteOrder) throws InvalidRangeException, IOException
Constructor. This is for HDF5 chunked data storage. The data is read by chunk, for efficiency.- Parameters:
v2
- Variable to index over; assumes that vinfo is the data objectwantSection
- the wanted section of data, contains a List of Range objects. must be completeraf
- the RandomAccessFilefilterProps
- set of filter properties from which filter object will be created- Throws:
InvalidRangeException
- if section invalid for this variableIOException
- on io error
-
-
Method Detail
-
getTotalNelems
public long getTotalNelems()
Description copied from interface:LayoutBB
Get total number of elements in the wanted subset.- Specified by:
getTotalNelems
in interfaceLayout
- Specified by:
getTotalNelems
in interfaceLayoutBB
- Returns:
- total number of elements in the wanted subset.
-
getElemSize
public int getElemSize()
Description copied from interface:LayoutBB
Get size of each element in bytes.- Specified by:
getElemSize
in interfaceLayout
- Specified by:
getElemSize
in interfaceLayoutBB
- Returns:
- size of each element in bytes.
-
hasNext
public boolean hasNext()
Description copied from interface:LayoutBB
Is there more to do
-
next
public LayoutBB.Chunk next()
Description copied from interface:LayoutBB
Get the next chunk
-
-