ddn.data.hdf5.h5object
HDF5 Object Wrapper
This module provides a D wrapper for generic HDF5 object operations. Objects in HDF5 include datasets, groups, and committed datatypes.
License
BSD-3-Clause
struct HDF5Object
Types 1
structHDF5Object
Static wrapper for generic HDF5 object operations.
This struct provides static methods for working with HDF5 objects (datasets, groups, and committed datatypes) in a generic way.
Example:
// Check if an object exists
if (HDF5Object.exists(file.handle(), "/mydata")) {
// Open the object
auto objId = HDF5Object.open(file.handle(), "/mydata");
scope(exit) HDF5Object.close(objId);
// Get object info
auto info = HDF5Object.getInfo(objId);
}Methods
hid_t open(hid_t locId, string name, hid_t lapl = H5P_DEFAULT)Opens an existing HDF5 object (dataset, group, or committed datatype).void close(hid_t objId)Closes an HDF5 object.bool exists(hid_t locId, string name, hid_t lapl = H5P_DEFAULT)Checks if a link to an object exists at the specified path.bool existsByName(hid_t locId, string name, hid_t lapl = H5P_DEFAULT)Checks if an object exists at the specified path.H5O_info2_t getInfo(hid_t objId, uint fields = H5O_INFO.BASIC)Gets information about an object by its identifier.H5O_info2_t getInfoByName(hid_t locId, string name,
uint fields = H5O_INFO.BASIC,
hid_t lapl = H5P_DEFAULT)Gets information about an object by name.H5O_type_t getType(hid_t objId)Gets the type of an object.H5O_type_t getTypeByName(hid_t locId, string name,
hid_t lapl = H5P_DEFAULT)Gets the type of an object by name.void copy(hid_t srcLoc, string srcName, hid_t dstLoc, string dstName,
hid_t ocpypl = H5P_DEFAULT, hid_t lcpl = H5P_DEFAULT)Copies an object from one location to another.void flush(hid_t objId)Flushes all buffers associated with an object to disk.void refresh(hid_t objId)Refreshes all buffers associated with an object.void incrRefcount(hid_t objId)Increments the reference count of an object.void decrRefcount(hid_t objId)Decrements the reference count of an object.