Source
// C++ informative line for the emacs editor: -*- C++ -*-
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Copyright by The HDF Group. *
* Copyright by the Board of Trustees of the University of Illinois. *
* All rights reserved. *
* *
* This file is part of HDF5. The full HDF5 copyright notice, including *
* terms governing use, modification, and redistribution, is contained in *
* the COPYING file, which can be found at the root of the source code *
* distribution tree, or in https://support.hdfgroup.org/ftp/HDF5/releases. *
* If you do not have access to either file, you may request a copy from *
* help@hdfgroup.org. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
namespace H5 {
/*! \class IdComponent
\brief Class IdComponent provides wrappers of the C functions that
operate on an HDF5 identifier.
In most cases, the C library handles these operations and an application
rarely needs them.
*/
class H5_DLLCPP IdComponent {
public:
// Increment reference counter.
void incRefCount(const hid_t obj_id) const;
void incRefCount() const;
// Decrement reference counter.
void decRefCount(const hid_t obj_id) const;
void decRefCount() const;
// Get the reference counter to this identifier.
int getCounter(const hid_t obj_id) const;
int getCounter() const;
// Returns an HDF5 object type, given the object id.
static H5I_type_t getHDFObjType(const hid_t obj_id);
// Returns an HDF5 object type of this object.
H5I_type_t getHDFObjType() const;
// Returns the number of members in a type.
static hsize_t getNumMembers(H5I_type_t type);
// Checks if the given ID is valid.