File indexing completed on 2024-04-06 12:01:30
0001 #ifndef CondCore_CondHDF5ESSource_h5_Group_h
0002 #define CondCore_CondHDF5ESSource_h5_Group_h
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022 #include <memory>
0023 #include <string>
0024
0025 #include "hdf5.h"
0026
0027
0028
0029
0030
0031 namespace cms::h5 {
0032 class File;
0033 class DataSet;
0034 class Attribute;
0035
0036 class Group {
0037 public:
0038 explicit Group(hid_t, std::string const&);
0039 explicit Group(hid_t, const void* iRef);
0040
0041 ~Group();
0042
0043 Group(const Group&) = delete;
0044 Group& operator=(const Group&) = delete;
0045 Group(Group&&) = delete;
0046 Group& operator=(Group&&) = delete;
0047
0048
0049 std::shared_ptr<Group> findGroup(std::string const& iName) const;
0050 std::shared_ptr<DataSet> findDataSet(std::string const& iName) const;
0051 std::shared_ptr<Attribute> findAttribute(std::string const& iName) const;
0052
0053 std::shared_ptr<Group> derefGroup(hobj_ref_t iRef) const;
0054 std::shared_ptr<DataSet> derefDataSet(hobj_ref_t iRef) const;
0055
0056 std::string name() const;
0057
0058 std::size_t getNumObjs() const;
0059 std::string getObjnameByIdx(std::size_t) const;
0060
0061
0062
0063
0064 private:
0065
0066
0067 hid_t id_;
0068 };
0069 }
0070 #endif