File indexing completed on 2024-04-06 12:01:30
0001 #ifndef CondCore_CondHDF5ESSource_DataSet_h
0002 #define CondCore_CondHDF5ESSource_DataSet_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 #include <vector>
0025
0026 #include "hdf5.h"
0027
0028
0029 #include "IOVSyncValue.h"
0030
0031
0032
0033 namespace cms::h5 {
0034 class File;
0035 class Group;
0036 class Attribute;
0037
0038 class DataSet {
0039 public:
0040 DataSet(hid_t iParentID, std::string const& iName);
0041 DataSet(hid_t iParentID, const void* iRef);
0042 ~DataSet();
0043
0044 DataSet(const DataSet&) = delete;
0045 DataSet& operator=(const DataSet&) = delete;
0046 DataSet(DataSet&&) = delete;
0047 DataSet& operator=(DataSet&&) = delete;
0048
0049
0050 std::shared_ptr<Attribute> findAttribute(std::string const& iName) const;
0051
0052 std::vector<hobj_ref_t> readRefs() const;
0053 std::vector<char> readBytes() const;
0054 std::vector<cond::hdf5::IOVSyncValue> readSyncValues() const;
0055
0056 std::size_t storageSize() const;
0057 std::size_t memorySize() const;
0058 uint64_t fileOffset() const;
0059 uint32_t layout() const;
0060
0061
0062
0063
0064
0065 private:
0066 std::size_t size() const;
0067
0068
0069 hid_t id_;
0070 };
0071
0072 }
0073 #endif