public interface IHDF5LongWriter extends IHDF5LongReader
long
values to HDF5 files.
Obtain an object implementing this interface by calling IHDF5Writer.int64()
or IHDF5Writer.uint64()
.
Note: This interface supports block access and sliced access (which is a special cases of block access) to arrays. The performance of this block access can vary greatly depending on how the data are layed out in the HDF5 file. For best performance, the block (or slice) dimension should be chosen to be equal to the chunk dimensions of the array, as in this case the block written / read are stored as consecutive value in the HDF5 file and one write / read access will suffice.
Note: If you need to convert from and to unsigned values, use the methods of
UnsignedIntUtils
.
Modifier and Type | Method and Description |
---|---|
void |
createArray(java.lang.String objectPath,
HDF5DataSetTemplate template)
Creates a
long array (of rank 1). |
void |
createArray(java.lang.String objectPath,
int size)
Creates a
long array (of rank 1). |
void |
createArray(java.lang.String objectPath,
int size,
HDF5IntStorageFeatures features)
Creates a
long array (of rank 1). |
void |
createArray(java.lang.String objectPath,
long size,
int blockSize)
Creates a
long array (of rank 1). |
void |
createArray(java.lang.String objectPath,
long size,
int blockSize,
HDF5IntStorageFeatures features)
Creates a
long array (of rank 1). |
HDF5DataSet |
createArrayAndOpen(java.lang.String objectPath,
HDF5DataSetTemplate template)
Creates a
long array (of rank 1) and opens it for reading and writing. |
HDF5DataSet |
createArrayAndOpen(java.lang.String objectPath,
int size)
Creates a
long array (of rank 1) and opens it for reading and writing. |
HDF5DataSet |
createArrayAndOpen(java.lang.String objectPath,
int size,
HDF5IntStorageFeatures features)
Creates a
long array (of rank 1) and opens it for reading and writing. |
HDF5DataSet |
createArrayAndOpen(java.lang.String objectPath,
long size,
int blockSize)
Creates a
long array (of rank 1) and opens it for reading and writing. |
HDF5DataSet |
createArrayAndOpen(java.lang.String objectPath,
long size,
int blockSize,
HDF5IntStorageFeatures features)
Creates a
long array (of rank 1) and opens it for reading and writing. |
HDF5DataSetTemplate |
createArrayTemplate(long size,
int blockSize,
HDF5IntStorageFeatures features)
Creates a
long array template (of rank 1) which can be used in
writeArray(String, long[], HDF5DataSetTemplate) to create data sets. |
void |
createMatrix(java.lang.String objectPath,
int sizeX,
int sizeY)
Creates a
long matrix (array of rank 2). |
void |
createMatrix(java.lang.String objectPath,
int sizeX,
int sizeY,
HDF5IntStorageFeatures features)
Creates a
long matrix (array of rank 2). |
void |
createMatrix(java.lang.String objectPath,
long sizeX,
long sizeY,
int blockSizeX,
int blockSizeY)
Creates a
long matrix (array of rank 2). |
void |
createMatrix(java.lang.String objectPath,
long sizeX,
long sizeY,
int blockSizeX,
int blockSizeY,
HDF5IntStorageFeatures features)
Creates a
long matrix (array of rank 2). |
void |
createMDArray(java.lang.String objectPath,
HDF5DataSetTemplate template)
Creates a multi-dimensional
long array. |
void |
createMDArray(java.lang.String objectPath,
int[] dimensions)
Creates a multi-dimensional
long array. |
void |
createMDArray(java.lang.String objectPath,
int[] dimensions,
HDF5IntStorageFeatures features)
Creates a multi-dimensional
long array. |
void |
createMDArray(java.lang.String objectPath,
long[] dimensions,
int[] blockDimensions)
Creates a multi-dimensional
long array. |
void |
createMDArray(java.lang.String objectPath,
long[] dimensions,
int[] blockDimensions,
HDF5IntStorageFeatures features)
Creates a multi-dimensional
long array. |
HDF5DataSet |
createMDArrayAndOpen(java.lang.String objectPath,
HDF5DataSetTemplate template)
Creates a multi-dimensional
long array and opens it for reading and writing. |
HDF5DataSet |
createMDArrayAndOpen(java.lang.String objectPath,
int[] dimensions)
Creates a multi-dimensional
long array and opens it for reading and writing. |
HDF5DataSet |
createMDArrayAndOpen(java.lang.String objectPath,
int[] dimensions,
HDF5IntStorageFeatures features)
Creates a multi-dimensional
long array and opens it for reading and writing. |
HDF5DataSet |
createMDArrayAndOpen(java.lang.String objectPath,
long[] dimensions,
int[] blockDimensions)
Creates a multi-dimensional
long array and opens it for reading and writing. |
HDF5DataSet |
createMDArrayAndOpen(java.lang.String objectPath,
long[] dimensions,
int[] blockDimensions,
HDF5IntStorageFeatures features)
Creates a multi-dimensional
long array. |
HDF5DataSetTemplate |
createMDArrayTemplate(long[] dimensions,
int[] blockSize,
HDF5IntStorageFeatures features)
Creates a multi-dimensional
long array template which can be used e.g. |
void |
setArrayAttr(java.lang.String objectPath,
java.lang.String name,
long[] value)
Set a
long[] attribute on the referenced object. |
void |
setAttr(java.lang.String objectPath,
java.lang.String name,
long value)
Set a
long attribute on the referenced object. |
void |
setMatrixAttr(java.lang.String objectPath,
java.lang.String name,
long[][] value)
Set a
long[][] attribute on the referenced object. |
void |
setMDArrayAttr(java.lang.String objectPath,
java.lang.String name,
ch.systemsx.cisd.base.mdarray.MDLongArray value)
Set a multi-dimensional code>long attribute on the referenced object.
|
void |
write(java.lang.String objectPath,
long value)
Writes out a
long value. |
void |
writeArray(java.lang.String objectPath,
long[] data)
Writes out a
long array (of rank 1). |
void |
writeArray(java.lang.String objectPath,
long[] data,
HDF5DataSetTemplate template)
Writes out a
long array (of rank 1). |
void |
writeArray(java.lang.String objectPath,
long[] data,
HDF5IntStorageFeatures features)
Writes out a
long array (of rank 1). |
void |
writeArrayBlock(HDF5DataSet dataSet,
long[] data,
long blockNumber)
Writes out a block of a
long array (of rank 1). |
void |
writeArrayBlock(java.lang.String objectPath,
long[] data,
long blockNumber)
Writes out a block of a
long array (of rank 1). |
void |
writeArrayBlockWithOffset(HDF5DataSet dataSet,
long[] data,
int dataSize,
long offset)
Writes out a block of a
long array (of rank 1). |
void |
writeArrayBlockWithOffset(java.lang.String objectPath,
long[] data,
int dataSize,
long offset)
Writes out a block of a
long array (of rank 1). |
void |
writeMatrix(java.lang.String objectPath,
long[][] data)
Writes out a
long matrix (array of rank 2). |
void |
writeMatrix(java.lang.String objectPath,
long[][] data,
HDF5IntStorageFeatures features)
Writes out a
long matrix (array of rank 2). |
void |
writeMatrixBlock(java.lang.String objectPath,
long[][] data,
long blockNumberX,
long blockNumberY)
Writes out a block of a
long matrix (array of rank 2). |
void |
writeMatrixBlockWithOffset(java.lang.String objectPath,
long[][] data,
int dataSizeX,
int dataSizeY,
long offsetX,
long offsetY)
Writes out a block of a
long matrix (array of rank 2). |
void |
writeMatrixBlockWithOffset(java.lang.String objectPath,
long[][] data,
long offsetX,
long offsetY)
Writes out a block of a
long matrix (array of rank 2). |
void |
writeMDArray(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
HDF5ArrayBlockParams params)
Writes out a block or a slice of a multi-dimensional
long array. |
void |
writeMDArray(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data)
Writes out a multi-dimensional
long array. |
void |
writeMDArray(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
HDF5DataSetTemplate template)
Writes out a multi-dimensional
long array. |
void |
writeMDArray(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
HDF5IntStorageFeatures features)
Writes out a multi-dimensional
long array. |
void |
writeMDArrayBlock(HDF5DataSet dataset,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] blockNumber)
Writes out a block of a multi-dimensional
long array. |
void |
writeMDArrayBlock(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] blockNumber)
Writes out a block of a multi-dimensional
long array. |
void |
writeMDArrayBlockWithOffset(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
int[] blockDimensions,
long[] offset,
int[] memoryOffset)
Writes out a block of a multi-dimensional
long array. |
void |
writeMDArrayBlockWithOffset(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] offset)
Writes out a block of a multi-dimensional
long array. |
void |
writeMDArrayBlockWithOffset(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
int[] blockDimensions,
long[] offset,
int[] memoryOffset)
Writes out a block of a multi-dimensional
long array. |
void |
writeMDArrayBlockWithOffset(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] offset)
Writes out a block of a multi-dimensional
long array. |
void |
writeMDArraySlice(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
IndexMap boundIndices)
Writes out a slice of a multi-dimensional
long array. |
void |
writeMDArraySlice(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] boundIndices)
Writes out a slice of a multi-dimensional
long array. |
void |
writeMDArraySlice(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
IndexMap boundIndices)
Writes out a slice of a multi-dimensional
long array. |
void |
writeMDArraySlice(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] boundIndices)
Writes out a slice of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlock(HDF5DataSet dataset,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] blockNumber,
IndexMap boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlock(HDF5DataSet dataset,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] blockNumber,
long[] boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlock(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] blockNumber,
IndexMap boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlock(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] blockNumber,
long[] boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlockWithOffset(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] offset,
IndexMap boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlockWithOffset(HDF5DataSet dataSet,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] offset,
long[] boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlockWithOffset(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] offset,
IndexMap boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
void |
writeSlicedMDArrayBlockWithOffset(java.lang.String objectPath,
ch.systemsx.cisd.base.mdarray.MDLongArray data,
long[] offset,
long[] boundIndices)
Writes out a sliced block of a multi-dimensional
long array. |
getArrayAttr, getArrayNaturalBlocks, getAttr, getMatrixAttr, getMDArrayAttr, getMDArrayNaturalBlocks, read, readArray, readArrayBlock, readArrayBlock, readArrayBlockWithOffset, readArrayBlockWithOffset, readMatrix, readMatrixBlock, readMatrixBlockWithOffset, readMDArray, readMDArray, readMDArray, readMDArrayBlock, readMDArrayBlock, readMDArrayBlockWithOffset, readMDArrayBlockWithOffset, readMDArraySlice, readMDArraySlice, readMDArraySlice, readMDArraySlice, readSlicedMDArrayBlock, readSlicedMDArrayBlock, readSlicedMDArrayBlock, readSlicedMDArrayBlock, readSlicedMDArrayBlockWithOffset, readSlicedMDArrayBlockWithOffset, readSlicedMDArrayBlockWithOffset, readSlicedMDArrayBlockWithOffset, readToMDArrayBlockWithOffset, readToMDArrayBlockWithOffset, readToMDArrayWithOffset, readToMDArrayWithOffset
void setAttr(java.lang.String objectPath, java.lang.String name, long value)
long
attribute on the referenced object.
The referenced object must exist, that is it need to have been written before by one of the
write()
methods.
objectPath
- The name of the object to add the attribute to.name
- The name of the attribute.value
- The value of the attribute.void setArrayAttr(java.lang.String objectPath, java.lang.String name, long[] value)
long[]
attribute on the referenced object.
The referenced object must exist, that is it need to have been written before by one of the
write()
methods.
objectPath
- The name of the object to add the attribute to.name
- The name of the attribute.value
- The value of the attribute.void setMDArrayAttr(java.lang.String objectPath, java.lang.String name, ch.systemsx.cisd.base.mdarray.MDLongArray value)
The referenced object must exist, that is it need to have been written before by one of the
write()
methods.
objectPath
- The name of the object to add the attribute to.name
- The name of the attribute.value
- The value of the attribute.void setMatrixAttr(java.lang.String objectPath, java.lang.String name, long[][] value)
long[][]
attribute on the referenced object.
The referenced object must exist, that is it need to have been written before by one of the
write()
methods.
objectPath
- The name of the object to add the attribute to.name
- The name of the attribute.value
- The value of the attribute.void write(java.lang.String objectPath, long value)
long
value.objectPath
- The name (including path information) of the data set object in the file.value
- The value to write.void writeArray(java.lang.String objectPath, long[] data)
long
array (of rank 1).objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
.void writeArray(java.lang.String objectPath, long[] data, HDF5IntStorageFeatures features)
long
array (of rank 1).objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
.features
- The storage features of the data set.void writeArray(java.lang.String objectPath, long[] data, HDF5DataSetTemplate template)
long
array (of rank 1). When creating many data sets with the same
features, this method will be faster than
writeArray(String, long[], HDF5IntStorageFeatures)
.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
.template
- The template to be used to determine the features of the data set.HDF5LibraryException
- If a data set with name objectPath
already exists.void createArray(java.lang.String objectPath, int size)
long
array (of rank 1).objectPath
- The name (including path information) of the data set object in the file.size
- When the writer is configured to use extendable data types (see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be size. When the writer is
configured to enforce a non-extendable data set, the initial size equals the
total size and will be size.HDF5DataSet createArrayAndOpen(java.lang.String objectPath, int size)
long
array (of rank 1) and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.size
- When the writer is configured to use extendable data types (see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be size. When the writer is
configured to enforce a non-extendable data set, the initial size equals the
total size and will be size.void createArray(java.lang.String objectPath, long size, int blockSize)
long
array (of rank 1).objectPath
- The name (including path information) of the data set object in the file.size
- The size of the long array to create. When using extendable data sets
((see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)), then no data
set smaller than this size can be created, however data sets may be larger.blockSize
- The size of one block (for block-wise IO). Ignored if non-extendable data
sets are used (see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
).HDF5DataSet createArrayAndOpen(java.lang.String objectPath, long size, int blockSize)
long
array (of rank 1) and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.size
- When the writer is configured to use extendable data types (see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be size. When the writer is
configured to enforce a non-extendable data set, the initial size equals the
total size and will be size.blockSize
- The size of one block (for block-wise IO). Ignored if non-extendable data
sets are used (see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
).void createArray(java.lang.String objectPath, int size, HDF5IntStorageFeatures features)
long
array (of rank 1).objectPath
- The name (including path information) of the data set object in the file.size
- The size of the long
array to create. When requesting a
chunked data set (e.g. HDF5IntStorageFeatures.INT_CHUNKED
),
the initial size of the array will be 0 and the chunk size will be arraySize.
When allowing a chunked data set (e.g.
HDF5IntStorageFeatures.INT_NO_COMPRESSION
when the writer is
not configured to avoid extendable data types, see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be arraySize. When enforcing a
on-extendable data set (e.g.
HDF5IntStorageFeatures.INT_CONTIGUOUS
), the initial size equals
the total size and will be arraySize.features
- The storage features of the data set.HDF5DataSet createArrayAndOpen(java.lang.String objectPath, int size, HDF5IntStorageFeatures features)
long
array (of rank 1) and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.size
- The size of the int
array to create. When requesting a
chunked data set (e.g. HDF5IntStorageFeatures.INT_CHUNKED
),
the initial size of the array will be 0 and the chunk size will be arraySize.
When allowing a chunked data set (e.g.
HDF5IntStorageFeatures.INT_NO_COMPRESSION
when the writer is
not configured to avoid extendable data types, see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be arraySize. When enforcing a
on-extendable data set (e.g.
HDF5IntStorageFeatures.INT_CONTIGUOUS
), the initial size equals
the total size and will be arraySize.features
- The storage features of the data set.void createArray(java.lang.String objectPath, long size, int blockSize, HDF5IntStorageFeatures features)
long
array (of rank 1).objectPath
- The name (including path information) of the data set object in the file.size
- The size of the int array to create. When using extendable data sets
((see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)), then no data
set smaller than this size can be created, however data sets may be larger.blockSize
- The size of one block (for block-wise IO). Ignored if no extendable data
sets are used (see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
) and
features
is HDF5IntStorageFeature.INT_NO_COMPRESSION
.features
- The storage features of the data set.HDF5DataSet createArrayAndOpen(java.lang.String objectPath, long size, int blockSize, HDF5IntStorageFeatures features)
long
array (of rank 1) and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.size
- The size of the int array to create. When using extendable data sets
((see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)), then no data
set smaller than this size can be created, however data sets may be larger.blockSize
- The size of one block (for block-wise IO). Ignored if no extendable data
sets are used (see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
) and
features
is HDF5IntStorageFeature.INT_NO_COMPRESSION
.features
- The storage features of the data set.void createArray(java.lang.String objectPath, HDF5DataSetTemplate template)
long
array (of rank 1). When creating many data sets with the same
features, this method will be faster than
createArray(String, long, int, HDF5IntStorageFeatures)
.objectPath
- The name (including path information) of the data set object in the file.template
- The template to be used to determine the features of the data set.HDF5LibraryException
- If a data set with name objectPath
already exists.HDF5DataSet createArrayAndOpen(java.lang.String objectPath, HDF5DataSetTemplate template)
long
array (of rank 1) and opens it for reading and writing.
When creating many data sets with the same features, this method will be faster than
createArrayAndOpen(String, long, int, HDF5IntStorageFeatures)
.objectPath
- The name (including path information) of the data set object in the file.template
- The template to be used to determine the features of the data set.HDF5LibraryException
- If a data set with name
objectPath
already exists.HDF5DataSetTemplate createArrayTemplate(long size, int blockSize, HDF5IntStorageFeatures features)
long
array template (of rank 1) which can be used in
writeArray(String, long[], HDF5DataSetTemplate)
to create data sets.
It is meant to be used when creating many data sets with the same features.
The template returned by this method must be closed after work, as otherwise resources of the HDF5 library are leaked.
size
- The size of the long array to be created. When using extendable data sets ((see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)), then no data set
smaller than this size can be created, however data sets may be larger.blockSize
- The size of one block (for block-wise IO). Ignored if no extendable data
sets are used (see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)
and features
is HDF5IntStorageFeature.INT_NO_COMPRESSION
.features
- The storage features of the data set.void writeArrayBlock(java.lang.String objectPath, long[] data, long blockNumber)
long
array (of rank 1). The data set needs to have
been created by createArray(String, long, int, HDF5IntStorageFeatures)
beforehand.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. The length defines the block size. Must not be
null
or of length 0.blockNumber
- The number of the block to write.void writeArrayBlock(HDF5DataSet dataSet, long[] data, long blockNumber)
long
array (of rank 1). The data set needs to have
been created by createArray(String, long, int, HDF5IntStorageFeatures)
beforehand.
This method is faster than writeArrayBlock(String, long[], long)
when called many times on the same data set.
dataSet
- The data set to write to.data
- The data to write. The length defines the block size. Must not be
null
or of length 0.blockNumber
- The number of the block to write.void writeArrayBlockWithOffset(java.lang.String objectPath, long[] data, int dataSize, long offset)
long
array (of rank 1). The data set needs to have
been created by createArray(String, long, int, HDF5IntStorageFeatures)
beforehand.
Use this method instead of writeArrayBlock(String, long[], long)
if the
total size of the data set is not a multiple of the block size.
objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. The length defines the block size. Must not be
null
or of length 0.dataSize
- The (real) size of data
(needs to be <= data.length
)offset
- The offset in the data set to start writing to.void writeArrayBlockWithOffset(HDF5DataSet dataSet, long[] data, int dataSize, long offset)
long
array (of rank 1). The data set needs to have
been created by createArray(String, long, int, HDF5IntStorageFeatures)
beforehand.
Use this method instead of writeArrayBlock(HDF5DataSet, long[], long)
if the
total size of the data set is not a multiple of the block size.
This method is faster than writeArrayBlockWithOffset(String, long[], int, long)
when called many times on the same data set.
dataSet
- The data set to write to.data
- The data to write. The length defines the block size. Must not be
null
or of length 0.offset
- The offset in the data set to start writing to.void writeMatrix(java.lang.String objectPath, long[][] data)
long
matrix (array of rank 2).objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.void writeMatrix(java.lang.String objectPath, long[][] data, HDF5IntStorageFeatures features)
long
matrix (array of rank 2).objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.features
- The storage features of the data set.void createMatrix(java.lang.String objectPath, int sizeX, int sizeY)
long
matrix (array of rank 2).objectPath
- The name (including path information) of the data set object in the file.sizeX
- The size of one block in the x dimension. See
createMDArray(String, int[])
on the different
meanings of this parameter.sizeY
- The size of one block in the y dimension. See
createMDArray(String, int[])
on the different
meanings of this parameter.void createMatrix(java.lang.String objectPath, int sizeX, int sizeY, HDF5IntStorageFeatures features)
long
matrix (array of rank 2).objectPath
- The name (including path information) of the data set object in the file.sizeX
- The size of one block in the x dimension. See
createMDArray(String, int[], HDF5IntStorageFeatures)
on the different
meanings of this parameter.sizeY
- The size of one block in the y dimension. See
createMDArray(String, int[], HDF5IntStorageFeatures)
on the different
meanings of this parameter.features
- The storage features of the data set.void createMatrix(java.lang.String objectPath, long sizeX, long sizeY, int blockSizeX, int blockSizeY)
long
matrix (array of rank 2).objectPath
- The name (including path information) of the data set object in the file.sizeX
- The size of the x dimension of the long matrix to create.sizeY
- The size of the y dimension of the long matrix to create.blockSizeX
- The size of one block in the x dimension.blockSizeY
- The size of one block in the y dimension.void createMatrix(java.lang.String objectPath, long sizeX, long sizeY, int blockSizeX, int blockSizeY, HDF5IntStorageFeatures features)
long
matrix (array of rank 2).objectPath
- The name (including path information) of the data set object in the file.sizeX
- The size of the x dimension of the long matrix to create.sizeY
- The size of the y dimension of the long matrix to create.blockSizeX
- The size of one block in the x dimension.blockSizeY
- The size of one block in the y dimension.features
- The storage features of the data set.void writeMatrixBlock(java.lang.String objectPath, long[][] data, long blockNumberX, long blockNumberY)
long
matrix (array of rank 2). The data set needs to
have been created by
createMatrix(String, long, long, int, int, HDF5IntStorageFeatures)
beforehand.
Use this method instead of
createMatrix(String, long, long, int, int, HDF5IntStorageFeatures)
if the total
size of the data set is not a multiple of the block size.
objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. The length defines the block size. Must not be
null
or of length 0.blockNumberX
- The block number in the x dimension (offset: multiply with
data.length
).blockNumberY
- The block number in the y dimension (offset: multiply with
data[0.length
).void writeMatrixBlockWithOffset(java.lang.String objectPath, long[][] data, long offsetX, long offsetY)
long
matrix (array of rank 2). The data set needs to
have been created by
createMatrix(String, long, long, int, int, HDF5IntStorageFeatures)
beforehand.
Use this method instead of writeMatrixBlock(String, long[][], long, long)
if
the total size of the data set is not a multiple of the block size.
objectPath
- The name (including path information) of the data set object in the file.data
- The data to write.offsetX
- The x offset in the data set to start writing to.offsetY
- The y offset in the data set to start writing to.void writeMatrixBlockWithOffset(java.lang.String objectPath, long[][] data, int dataSizeX, int dataSizeY, long offsetX, long offsetY)
long
matrix (array of rank 2). The data set needs to
have been created by
createMatrix(String, long, long, int, int, HDF5IntStorageFeatures)
beforehand.
Use this method instead of writeMatrixBlock(String, long[][], long, long)
if
the total size of the data set is not a multiple of the block size.
objectPath
- The name (including path information) of the data set object in the file.data
- The data to write.dataSizeX
- The (real) size of data
along the x axis (needs to be
<= data.length
)dataSizeY
- The (real) size of data
along the y axis (needs to be
<= data[0].length
)offsetX
- The x offset in the data set to start writing to.offsetY
- The y offset in the data set to start writing to.void writeMDArray(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data)
long
array.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.void writeMDArray(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, HDF5IntStorageFeatures features)
long
array.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.features
- The storage features of the data set.void writeMDArray(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, HDF5ArrayBlockParams params)
long
array.dataSet
- The data set to write to.data
- The data to write. Must not be null
.params
- The parameter block specifying the block or slice to read from the array.void writeMDArray(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, HDF5DataSetTemplate template)
long
array. When creating many data sets with the same
features, this method will be faster than
writeMDArray(String, MDLongArray, HDF5IntStorageFeatures)
.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
.template
- The template to be used to determine the features of the data set.HDF5LibraryException
- If a data set with name objectPath
already exists.void writeMDArraySlice(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, IndexMap boundIndices)
long
array. The slice is defined by
"bound indices", each of which is fixed to a given value. The data object only
contains the free (i.e. non-fixed) indices.
Note:The object identified by objectPath needs to exist when this method is called. This method will not create the array.
objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.boundIndices
- The mapping of indices to index values which should be bound. For example
a map of new IndexMap().mapTo(2, 5).mapTo(4, 7)
has 2 and 4 as bound
indices and binds them to the values 5 and 7, respectively.void writeMDArraySlice(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, IndexMap boundIndices)
long
array. The slice is defined by
"bound indices", each of which is fixed to a given value. The data object only
contains the free (i.e. non-fixed) indices.dataSet
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.boundIndices
- The mapping of indices to index values which should be bound. For example
a map of new IndexMap().mapTo(2, 5).mapTo(4, 7)
has 2 and 4 as bound
indices and binds them to the values 5 and 7, respectively.void writeMDArraySlice(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] boundIndices)
long
array. The slice is defined by
"bound indices", each of which is fixed to a given value. The data object only
contains the free (i.e. non-fixed) indices.
Note:The object identified by objectPath needs to exist when this method is called. This method will not create the array.
objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeMDArraySlice(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] boundIndices)
long
array. The slice is defined by
"bound indices", each of which is fixed to a given value. The data object only
contains the free (i.e. non-fixed) indices.dataSet
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void createMDArray(java.lang.String objectPath, int[] dimensions)
long
array.objectPath
- The name (including path information) of the data set object in the file.dimensions
- When the writer is configured to use extendable data types (see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial dimensions
and the dimensions of a chunk of the array will be dimensions. When the
writer is configured to enforce a non-extendable data set, the initial dimensions
equal the dimensions and will be dimensions.HDF5DataSet createMDArrayAndOpen(java.lang.String objectPath, int[] dimensions)
long
array and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.dimensions
- When the writer is configured to use extendable data types (see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial dimensions
and the dimensions of a chunk of the array will be dimensions. When the
writer is configured to enforce a non-extendable data set, the initial dimensions
equal the dimensions and will be dimensions.void createMDArray(java.lang.String objectPath, long[] dimensions, int[] blockDimensions)
long
array.objectPath
- The name (including path information) of the data set object in the file.dimensions
- The dimensions of the array.blockDimensions
- The dimensions of one block (chunk) of the array.HDF5DataSet createMDArrayAndOpen(java.lang.String objectPath, long[] dimensions, int[] blockDimensions)
long
array and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.dimensions
- The dimensions of the array.blockDimensions
- The dimensions of one block (chunk) of the array.void createMDArray(java.lang.String objectPath, int[] dimensions, HDF5IntStorageFeatures features)
long
array.objectPath
- The name (including path information) of the data set object in the file.dimensions
- The dimensions of the long
array to create. When requesting
a chunked data set (e.g. HDF5IntStorageFeatures.INT_CHUNKED
),
the initial size of the array will be 0 and the chunk size will be dimensions.
When allowing a chunked data set (e.g.
HDF5IntStorageFeatures.INT_NO_COMPRESSION
when the writer is
not configured to avoid extendable data types, see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be dimensions. When enforcing a
on-extendable data set (e.g.
HDF5IntStorageFeatures.INT_CONTIGUOUS
), the initial size equals
the total size and will be dimensions.features
- The storage features of the data set.HDF5DataSet createMDArrayAndOpen(java.lang.String objectPath, int[] dimensions, HDF5IntStorageFeatures features)
long
array and opens it for reading and writing.objectPath
- The name (including path information) of the data set object in the file.dimensions
- The dimensions of the long
array to create. When requesting
a chunked data set (e.g. HDF5IntStorageFeatures.INT_CHUNKED
),
the initial size of the array will be 0 and the chunk size will be dimensions.
When allowing a chunked data set (e.g.
HDF5IntStorageFeatures.INT_NO_COMPRESSION
when the writer is
not configured to avoid extendable data types, see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
), the initial size
and the chunk size of the array will be dimensions. When enforcing a
on-extendable data set (e.g.
HDF5IntStorageFeatures.INT_CONTIGUOUS
), the initial size equals
the total size and will be dimensions.features
- The storage features of the data set.void createMDArray(java.lang.String objectPath, long[] dimensions, int[] blockDimensions, HDF5IntStorageFeatures features)
long
array.objectPath
- The name (including path information) of the data set object in the file.dimensions
- The dimensions of the array.blockDimensions
- The dimensions of one block (chunk) of the array.features
- The storage features of the data set.HDF5DataSet createMDArrayAndOpen(java.lang.String objectPath, long[] dimensions, int[] blockDimensions, HDF5IntStorageFeatures features)
long
array.objectPath
- The name (including path information) of the data set object in the file.dimensions
- The dimensions of the array.blockDimensions
- The dimensions of one block (chunk) of the array.features
- The storage features of the data set.void createMDArray(java.lang.String objectPath, HDF5DataSetTemplate template)
long
array. When creating many data sets with the same
features, this method will be faster than
createMDArray(String, long[], int[], HDF5IntStorageFeatures)
.objectPath
- The name (including path information) of the data set object in the file.template
- The template to be used to determine the features of the data set.HDF5LibraryException
- If a data set with name objectPath
already exists.HDF5DataSet createMDArrayAndOpen(java.lang.String objectPath, HDF5DataSetTemplate template)
long
array and opens it for reading and writing.
When creating many data sets with the same features, this method will be faster than
createMDArrayAndOpen(String, long[], int[], HDF5IntStorageFeatures)
.objectPath
- The name (including path information) of the data set object in the file.template
- The template to be used to determine the features of the data set.HDF5LibraryException
- If a data set with name objectPath
already exists.HDF5DataSetTemplate createMDArrayTemplate(long[] dimensions, int[] blockSize, HDF5IntStorageFeatures features)
long
array template which can be used e.g. in
writeArray(String, long[], HDF5DataSetTemplate)
to create data sets.
It is meant to be used when creating many data sets with the same features.
The template returned by this method must be closed after work, as otherwise resources of the HDF5 library are leaked.
dimensions
- The dimensions of the array. When using extendable data sets ((see
IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)), then no data set
smaller than this size can be created, however data sets may be larger.blockSize
- The size of one block (for block-wise IO). Ignored if no extendable data
sets are used (see IHDF5WriterConfigurator.dontUseExtendableDataTypes()
)
and features
doesn't enforce them.features
- The storage features of the data set.void writeMDArrayBlock(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] blockNumber)
long
array.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.blockNumber
- The block number in each dimension (offset: multiply with the extend in
the according dimension).void writeMDArrayBlock(HDF5DataSet dataset, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] blockNumber)
long
array.dataset
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.blockNumber
- The block number in each dimension (offset: multiply with the extend in
the according dimension).void writeSlicedMDArrayBlock(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] blockNumber, IndexMap boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.blockNumber
- The block number in each dimension (offset: multiply with the extend in
the according dimension).boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeSlicedMDArrayBlock(HDF5DataSet dataset, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] blockNumber, IndexMap boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.dataset
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.blockNumber
- The block number in each dimension (offset: multiply with the extend in
the according dimension).boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeSlicedMDArrayBlock(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] blockNumber, long[] boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.blockNumber
- The block number in each dimension (offset: multiply with the extend in
the according dimension).boundIndices
- The mapping of indices to index values which should be bound. For example
a map of new IndexMap().mapTo(2, 5).mapTo(4, 7)
has 2 and 4 as bound
indices and binds them to the values 5 and 7, respectively.void writeSlicedMDArrayBlock(HDF5DataSet dataset, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] blockNumber, long[] boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.dataset
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.blockNumber
- The block number in each dimension (offset: multiply with the extend in
the according dimension).boundIndices
- The mapping of indices to index values which should be bound. For example
a map of new IndexMap().mapTo(2, 5).mapTo(4, 7)
has 2 and 4 as bound
indices and binds them to the values 5 and 7, respectively.void writeMDArrayBlockWithOffset(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] offset)
long
array.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.offset
- The offset in the data set to start writing to in each dimension.void writeMDArrayBlockWithOffset(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] offset)
long
array.dataSet
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.offset
- The offset in the data set to start writing to in each dimension.void writeSlicedMDArrayBlockWithOffset(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] offset, IndexMap boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.offset
- The offset in the data set to start writing to in each dimension.boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeSlicedMDArrayBlockWithOffset(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] offset, IndexMap boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.dataSet
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.offset
- The offset in the data set to start writing to in each dimension.boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeSlicedMDArrayBlockWithOffset(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] offset, long[] boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
. All columns need to have the
same length.offset
- The offset in the data set to start writing to in each dimension.boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeSlicedMDArrayBlockWithOffset(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, long[] offset, long[] boundIndices)
long
array. The slice is
defined by "bound indices", each of which is fixed to a given value. The data
object only contains the free (i.e. non-fixed) indices.dataSet
- The data set to write to.data
- The data to write. Must not be null
. All columns need to have the
same length.offset
- The offset in the data set to start writing to in each dimension.boundIndices
- The array containing the values of the bound indices at the respective
index positions, and -1 at the free index positions. For example an array of
new long[] { -1, -1, 5, -1, 7, -1 }
has 2 and 4 as bound indices and
binds them to the values 5 and 7, respectively.void writeMDArrayBlockWithOffset(java.lang.String objectPath, ch.systemsx.cisd.base.mdarray.MDLongArray data, int[] blockDimensions, long[] offset, int[] memoryOffset)
long
array.objectPath
- The name (including path information) of the data set object in the file.data
- The data to write. Must not be null
.blockDimensions
- The dimensions of the block to write to the data set.offset
- The offset of the block in the data set to start writing to in each dimension.memoryOffset
- The offset of the block in the data array.void writeMDArrayBlockWithOffset(HDF5DataSet dataSet, ch.systemsx.cisd.base.mdarray.MDLongArray data, int[] blockDimensions, long[] offset, int[] memoryOffset)
long
array.dataSet
- The data set to write to.data
- The data to write. Must not be null
.blockDimensions
- The dimensions of the block to write to the data set.offset
- The offset of the block in the data set to start writing to in each dimension.memoryOffset
- The offset of the block in the data array.