Field3D
Hdf5Util::H5ScopedGopen Class Reference

Scoped object - opens a group on creation and closes it on destruction. More...

#include <Hdf5Util.h>

Inheritance diagram for Hdf5Util::H5ScopedGopen:
Hdf5Util::H5Base

Public Member Functions

 H5ScopedGopen ()
 
 H5ScopedGopen (hid_t parentLocation, const std::string &name)
 
 H5ScopedGopen (hid_t parentLocation, const std::string &name, hid_t gapl_id)
 
void open (hid_t parentLocation, const std::string &name)
 
void open (hid_t parentLocation, const std::string &name, hid_t gapl_id)
 
 ~H5ScopedGopen ()
 
- Public Member Functions inherited from Hdf5Util::H5Base
 H5Base ()
 
hid_t id () const
 Query the hid_t value. More...
 
 operator hid_t ()
 Implicit cast to hid_t. More...
 

Additional Inherited Members

- Protected Attributes inherited from Hdf5Util::H5Base
hid_t m_id
 

Detailed Description

Scoped object - opens a group on creation and closes it on destruction.

Definition at line 176 of file Hdf5Util.h.

Constructor & Destructor Documentation

Hdf5Util::H5ScopedGopen::H5ScopedGopen ( )
inline

Definition at line 179 of file Hdf5Util.h.

180  : H5Base()
181  {
182  // Empty
183  }
Hdf5Util::H5ScopedGopen::H5ScopedGopen ( hid_t  parentLocation,
const std::string &  name 
)
inline

Definition at line 184 of file Hdf5Util.h.

References open().

185  {
186  open(parentLocation, name);
187  }
void open(hid_t parentLocation, const std::string &name)
Definition: Hdf5Util.h:192
Hdf5Util::H5ScopedGopen::H5ScopedGopen ( hid_t  parentLocation,
const std::string &  name,
hid_t  gapl_id 
)
inline

Definition at line 188 of file Hdf5Util.h.

References open().

189  {
190  open(parentLocation, name, gapl_id);
191  }
void open(hid_t parentLocation, const std::string &name)
Definition: Hdf5Util.h:192
Hdf5Util::H5ScopedGopen::~H5ScopedGopen ( )
inline

Definition at line 201 of file Hdf5Util.h.

References Hdf5Util::H5Base::m_id.

202  {
203  if (m_id >= 0)
204  H5Gclose(m_id);
205  }

Member Function Documentation

void Hdf5Util::H5ScopedGopen::open ( hid_t  parentLocation,
const std::string &  name 
)
inline

Definition at line 192 of file Hdf5Util.h.

References Hdf5Util::H5Base::m_id.

Referenced by H5ScopedGopen().

193  {
194  m_id = H5Gopen(parentLocation, name.c_str(), H5P_DEFAULT);
195  }
void Hdf5Util::H5ScopedGopen::open ( hid_t  parentLocation,
const std::string &  name,
hid_t  gapl_id 
)
inline

Definition at line 196 of file Hdf5Util.h.

References Hdf5Util::H5Base::m_id.

197  {
198  m_id = H5Gopen(parentLocation, name.c_str(), gapl_id);
199  }

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