HighFive 2.10.1
HighFive - Header-only C++ HDF5 interface
Loading...
Searching...
No Matches
HighFive::CompoundType Class Reference

Create a compound HDF5 datatype. More...

#include <H5DataType.hpp>

Inheritance diagram for HighFive::CompoundType:
Collaboration diagram for HighFive::CompoundType:

Classes

struct  member_def
 Use for defining a sub-type of compound type. More...
 

Public Member Functions

 CompoundType (const CompoundType &other)=default
 
 CompoundType (const std::vector< member_def > &t_members, size_t size=0)
 Initializes a compound type from a vector of member definitions.
 
 CompoundType (std::vector< member_def > &&t_members, size_t size=0)
 
 CompoundType (const std::initializer_list< member_def > &t_members, size_t size=0)
 
 CompoundType (DataType &&type)
 Initializes a compound type from a DataType.
 
void commit (const Object &object, const std::string &name) const
 Commit datatype into the given Object.
 
const std::vector< member_def > & getMembers () const noexcept
 Get read access to the CompoundType members.
 
- Public Member Functions inherited from HighFive::DataType
bool operator== (const DataType &other) const
 
bool operator!= (const DataType &other) const
 
DataTypeClass getClass () const
 Return the fundamental type.
 
size_t getSize () const
 Returns the length (in bytes) of this type elements.
 
std::string string () const
 Returns a friendly description of the type (e.g. Float32)
 
bool isVariableStr () const
 Returns whether the type is a variable-length string.
 
bool isFixedLenStr () const
 Returns whether the type is a fixed-length string.
 
StringType asStringType () const
 Returns this datatype as a StringType.
 
bool empty () const noexcept
 Check the DataType was default constructed.
 
bool isReference () const
 Returns whether the type is a Reference.
 
DataTypeCreateProps getCreatePropertyList () const
 Get the list of properties for creation of this DataType.
 
- Public Member Functions inherited from HighFive::Object
 Object (Object &&other) noexcept
 
 ~Object ()
 
bool isValid () const noexcept
 isValid
 
hid_t getId () const noexcept
 getId
 
ObjectInfo getInfo () const
 Retrieve several infos about the current object (address, dates, etc)
 
ObjectType getType () const
 Gets the fundamental type of the object (dataset, group, etc)
 
bool operator== (const Object &other) const noexcept
 

Additional Inherited Members

- Protected Member Functions inherited from HighFive::DataType
 Object (Object &&other) noexcept
 
 Object ()
 
 Object (const Object &other)
 
 Object (hid_t)
 
- Protected Member Functions inherited from HighFive::Object
 Object ()
 
 Object (const Object &other)
 
 Object (hid_t)
 
Objectoperator= (const Object &other)
 
- Protected Attributes inherited from HighFive::Object
hid_t _hid
 

Detailed Description

Create a compound HDF5 datatype.

Constructor & Destructor Documentation

◆ CompoundType() [1/5]

HighFive::CompoundType::CompoundType ( const CompoundType & other)
default

◆ CompoundType() [2/5]

HighFive::CompoundType::CompoundType ( const std::vector< member_def > & t_members,
size_t size = 0 )
inline

Initializes a compound type from a vector of member definitions.

Parameters
t_members
size

◆ CompoundType() [3/5]

HighFive::CompoundType::CompoundType ( std::vector< member_def > && t_members,
size_t size = 0 )
inline

◆ CompoundType() [4/5]

HighFive::CompoundType::CompoundType ( const std::initializer_list< member_def > & t_members,
size_t size = 0 )
inline

◆ CompoundType() [5/5]

HighFive::CompoundType::CompoundType ( DataType && type)
inline

Initializes a compound type from a DataType.

Parameters
type

Member Function Documentation

◆ commit()

void HighFive::CompoundType::commit ( const Object & object,
const std::string & name ) const
inline

Commit datatype into the given Object.

Parameters
objectLocation to commit object into
nameName to give the datatype

◆ getMembers()

const std::vector< member_def > & HighFive::CompoundType::getMembers ( ) const
inlinenoexcept

Get read access to the CompoundType members.


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