public class HDF5OpaqueReader extends java.lang.Object implements IHDF5OpaqueReader
IHDF5OpaqueReader
Modifier and Type | Method and Description |
---|---|
byte[] |
getArrayAttr(java.lang.String objectPath,
java.lang.String attributeName)
Gets the byte array values of an attribute attributeName of object
objectPath.
|
java.lang.Iterable<HDF5DataBlock<byte[]>> |
getArrayNaturalBlocks(java.lang.String dataSetPath)
Provides all natural blocks of this one-dimensional data set to iterate over.
|
byte[] |
readArray(java.lang.String objectPath)
Reads the data set objectPath as byte array.
|
byte[] |
readArrayBlock(java.lang.String objectPath,
int blockSize,
long blockNumber)
Reads a block from data set objectPath as byte array.
|
byte[] |
readArrayBlockWithOffset(java.lang.String objectPath,
int blockSize,
long offset)
Reads a block from data set objectPath as byte array.
|
int |
readArrayToBlockWithOffset(java.lang.String objectPath,
byte[] buffer,
int blockSize,
long offset,
int memoryOffset)
Reads a block from data set objectPath as byte array into buffer.
|
java.lang.String |
tryGetOpaqueTag(java.lang.String objectPath)
Returns the tag of the opaque data type associated with objectPath, or
null , if objectPath is not of an opaque data type (i.e. |
HDF5OpaqueType |
tryGetOpaqueType(java.lang.String objectPath)
Returns the opaque data type or
null , if objectPath is not of such a
data type. |
public java.lang.String tryGetOpaqueTag(java.lang.String objectPath)
IHDF5OpaqueReader
null
, if objectPath is not of an opaque data type (i.e. if
reader.getDataSetInformation(objectPath).getTypeInformation().getDataClass() != HDF5DataClass.OPAQUE
).tryGetOpaqueTag
in interface IHDF5OpaqueReader
objectPath
- The name (including path information) of the data set object in the file.null
.public HDF5OpaqueType tryGetOpaqueType(java.lang.String objectPath)
IHDF5OpaqueReader
null
, if objectPath is not of such a
data type.tryGetOpaqueType
in interface IHDF5OpaqueReader
objectPath
- The name (including path information) of the data set object in the file.null
.public byte[] readArray(java.lang.String objectPath)
IHDF5OpaqueReader
readArray
in interface IHDF5OpaqueReader
objectPath
- The name (including path information) of the data set object in the file.public byte[] getArrayAttr(java.lang.String objectPath, java.lang.String attributeName)
IHDF5OpaqueReader
getArrayAttr
in interface IHDF5OpaqueReader
public byte[] readArrayBlock(java.lang.String objectPath, int blockSize, long blockNumber) throws HDF5JavaException
IHDF5OpaqueReader
readArrayBlock
in interface IHDF5OpaqueReader
objectPath
- The name (including path information) of the data set object in the file.blockSize
- The block size in numbers of elements (this will be the length of the
byte[]
returned, divided by the size of one element).blockNumber
- The number of the block to read (starting with 0, offset: multiply with
blockSize).HDF5JavaException
- If the data set is not of rank 1 or is a String.public byte[] readArrayBlockWithOffset(java.lang.String objectPath, int blockSize, long offset) throws HDF5JavaException
IHDF5OpaqueReader
readArrayBlockWithOffset
in interface IHDF5OpaqueReader
objectPath
- The name (including path information) of the data set object in the file.blockSize
- The block size in numbers of elements (this will be the length of the
byte[]
returned, divided by the size of one element).offset
- The offset of the block to read as number of elements (starting with 0).HDF5JavaException
- If the data set is not of rank 1.public int readArrayToBlockWithOffset(java.lang.String objectPath, byte[] buffer, int blockSize, long offset, int memoryOffset) throws HDF5JavaException
IHDF5OpaqueReader
readArrayToBlockWithOffset
in interface IHDF5OpaqueReader
objectPath
- The name (including path information) of the data set object in the file.buffer
- The buffer to read the values in.blockSize
- The block size in numbers of elements (this will be the length of the
byte[]
returned, divided by the size of one element).offset
- The offset of the block in the data set as number of elements (zero-based).memoryOffset
- The offset of the block in buffer as number of elements
(zero-based).HDF5JavaException
- If the data set is not of rank 1.public java.lang.Iterable<HDF5DataBlock<byte[]>> getArrayNaturalBlocks(java.lang.String dataSetPath) throws HDF5JavaException
IHDF5OpaqueReader
getArrayNaturalBlocks
in interface IHDF5OpaqueReader
HDF5JavaException
- If the data set is not of rank 1.HDF5DataBlock