HDF5 C++ API  1.8.13
 All Classes Namespaces Functions Variables Typedefs Pages
H5Group.h
1 // C++ informative line for the emacs editor: -*- C++ -*-
2 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
3  * Copyright by The HDF Group. *
4  * Copyright by the Board of Trustees of the University of Illinois. *
5  * All rights reserved. *
6  * *
7  * This file is part of HDF5. The full HDF5 copyright notice, including *
8  * terms governing use, modification, and redistribution, is contained in *
9  * the files COPYING and Copyright.html. COPYING can be found at the root *
10  * of the source code distribution tree; Copyright.html can be found at the *
11  * root level of an installed copy of the electronic HDF5 document set and *
12  * is linked from the top-level documents page. It can also be found at *
13  * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have *
14  * access to either file, you may request a copy from help@hdfgroup.org. *
15  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
16 
17 #ifndef __H5Group_H
18 #define __H5Group_H
19 
20 #ifndef H5_NO_NAMESPACE
21 namespace H5 {
22 #endif
23 
29 class H5_DLLCPP Group : public H5Object, public CommonFG {
30  public:
31  // Close this group.
32  virtual void close();
33 
35  virtual H5std_string fromClass () const { return("Group"); }
36 
37  // Throw group exception.
38  virtual void throwException(const H5std_string& func_name, const H5std_string& msg) const;
39 
40  // for CommonFG to get the file id.
41  virtual hid_t getLocId() const;
42 
43  // Creates a group by way of dereference.
44  Group(const H5Location& loc, const void* ref, H5R_type_t ref_type = H5R_OBJECT, const PropList& plist = PropList::DEFAULT);
45  Group(const Attribute& attr, const void* ref, H5R_type_t ref_type = H5R_OBJECT, const PropList& plist = PropList::DEFAULT);
46 
47  // default constructor
48  Group();
49 
50  // Copy constructor: makes a copy of the original object
51  Group(const Group& original);
52 
53  // Gets the group id.
54  virtual hid_t getId() const;
55 
56  // Destructor
57  virtual ~Group();
58 
59  // Creates a copy of an existing group using its id.
60  Group( const hid_t group_id );
61 
62  protected:
63 #ifndef DOXYGEN_SHOULD_SKIP_THIS
64  // Sets the group id.
65  virtual void p_setId(const hid_t new_id);
66 #endif // DOXYGEN_SHOULD_SKIP_THIS
67 
68  private:
69  hid_t id; // HDF5 group id
70 };
71 #ifndef H5_NO_NAMESPACE
72 }
73 #endif
74 #endif // __H5Group_H
Class Group represents an HDF5 group.
Definition: H5Group.h:29
virtual H5std_string fromClass() const
Returns this class name.
Definition: H5Group.h:35
Class Attribute operates on HDF5 attributes.
Definition: H5Attribute.h:32
Class H5Object is a bridge between H5Location and DataSet, DataType, and Group.
Definition: H5Object.h:47
H5Location is an abstract base class, added in version 1.8.12.
Definition: H5Location.h:50
Class PropList provides operations for generic property lists.
Definition: H5PropList.h:25
static const PropList DEFAULT
Constant for default property.
Definition: H5PropList.h:28
CommonFG is an abstract base class of H5File and H5Group.
Definition: H5CommonFG.h:34