Field3D

Scoped object - opens an attribute data space on creation and closes it on destruction. More...

#include <Hdf5Util.h>

Inheritance diagram for Hdf5Util::H5ScopedAget_space:
Hdf5Util::H5Base

Public Member Functions

 H5ScopedAget_space (hid_t dataset_id)
 
 ~H5ScopedAget_space ()
 
- 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 an attribute data space on creation and closes it on destruction.

Definition at line 262 of file Hdf5Util.h.

Constructor & Destructor Documentation

Hdf5Util::H5ScopedAget_space::H5ScopedAget_space ( hid_t  dataset_id)
inline

Definition at line 265 of file Hdf5Util.h.

References Hdf5Util::H5Base::m_id.

266  {
267  m_id = H5Aget_space(dataset_id);
268  if (m_id < 0)
269  throw Exc::AttrGetSpaceException("Couldn't get attribute space");
270  }
Hdf5Util::H5ScopedAget_space::~H5ScopedAget_space ( )
inline

Definition at line 271 of file Hdf5Util.h.

References Hdf5Util::H5Base::m_id.

272  {
273  if (m_id >= 0)
274  H5Sclose(m_id);
275  }

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