ddn.data.hdf5.datatype
HDF5 Datatype Wrapper
This module provides a D wrapper for HDF5 datatype operations with RAII semantics for automatic resource management.
License
BSD-3-Clause
struct Datatype
Types 1
structDatatype
RAII wrapper for HDF5 datatype handles.
This struct manages an HDF5 datatype handle and automatically closes it when the struct goes out of scope. Copy is disabled to prevent double-close issues; use dup() for explicit copying.
Example:
// Get a native integer type
auto intType = Datatype.nativeInt();
// Create a compound type
auto compType = Datatype.createCompound(16);Fields
private hid_t _idprivate bool _ownedMethods
void close()Explicitly closes the datatype handle.H5T_class_t typeClass()Gets the class of the datatype.size_t size()Gets the size of the datatype in bytes.void insertMember(string name, size_t offset, ref Datatype memberType)Inserts a member into a compound datatype.void pack()Packs a compound datatype to minimize storage.int numMembers()Gets the number of members in a compound datatype.void setSize(size_t newSize)Sets the size of the datatype.Destructors
~thisDestructor that automatically closes the datatype handle.