Theoretica
Mathematical Library
Loading...
Searching...
No Matches
theoretica::io::hdf5_node Class Reference

Represents a single node (group or dataset) in the HDF5 file hierarchy. More...

#include <hdf5.h>

Public Member Functions

bool is_group () const noexcept
 Check whether the node is a group.
 
bool is_dataset () const noexcept
 Check whether the node is a dataset.
 
hdf5_nodeoperator[] (const std::string &child_name)
 Dictionary-like access to child nodes by name.
 
const hdf5_nodeoperator[] (const std::string &child_name) const
 Read-only dictionary-like access to child nodes by name.
 

Public Attributes

std::string name
 The local name of the node (e.g. "my_dataset")
 
std::string path
 The absolute internal path to the node (e.g.
 
HDF5NodeType type
 The type of the node.
 
std::vector< size_tdimensions
 For datasets, the dimensions of the array.
 
std::vector< std::string > attributes
 List of metadata attribute names attached to the node.
 
std::unordered_map< std::string, hdf5_nodechildren
 For groups, the child nodes indexed by their local name.
 

Detailed Description

Represents a single node (group or dataset) in the HDF5 file hierarchy.

Member Function Documentation

◆ operator[]() [1/2]

hdf5_node & theoretica::io::hdf5_node::operator[] ( const std::string &  child_name)
inline

Dictionary-like access to child nodes by name.

Parameters
child_nameThe local name of the child node
Returns
Reference to the child node

◆ operator[]() [2/2]

const hdf5_node & theoretica::io::hdf5_node::operator[] ( const std::string &  child_name) const
inline

Read-only dictionary-like access to child nodes by name.

Parameters
child_nameThe local name of the child node
Returns
Const reference to the child node

Member Data Documentation

◆ path

std::string theoretica::io::hdf5_node::path

The absolute internal path to the node (e.g.

"/group/subgroup/my_dataset")


The documentation for this class was generated from the following file: