9 #ifndef H5OBJECT_MISC_HPP
10 #define H5OBJECT_MISC_HPP
28 other._hid = H5I_INVALID_HID;
33 if (
_hid != H5I_INVALID_HID)
46 std::cerr <<
"HighFive::~Object: reference counter decrease failure"
52 return (
_hid != H5I_INVALID_HID) && (H5Iis_valid(
_hid) !=
false);
59 static inline ObjectType _convert_object_type(
const H5I_type_t& h5type) {
81 if ((h5type = H5Iget_type(
_hid)) == H5I_BADID) {
82 HDF5ErrMapper::ToException<ObjectException>(
"Invalid hid or object type");
84 return _convert_object_type(h5type);
89 #if (H5Oget_info_vers < 3)
94 HDF5ErrMapper::ToException<ObjectException>(
"Unable to obtain info for object");
100 return raw_info.addr;
106 return raw_info.btime;
109 return raw_info.mtime;
Exception specific to HighFive Object interface.
Definition: H5Exception.hpp:75
Definition: H5Object.hpp:36
hid_t getId() const noexcept
getId
Definition: H5Object_misc.hpp:55
ObjectInfo getInfo() const
Retrieve several infos about the current object (address, dates, etc)
Definition: H5Object_misc.hpp:87
~Object()
Definition: H5Object_misc.hpp:44
ObjectType getType() const
Gets the fundamental type of the object (dataset, group, etc)
Definition: H5Object_misc.hpp:78
Object()
Definition: H5Object_misc.hpp:16
bool isValid() const noexcept
isValid
Definition: H5Object_misc.hpp:51
hid_t _hid
Definition: H5Object.hpp:87
Object & operator=(const Object &other)
Definition: H5Object_misc.hpp:31
A class for accessing hdf5 objects info.
Definition: H5Object.hpp:100
time_t getCreationTime() const noexcept
Retrieve the object's creation time.
Definition: H5Object_misc.hpp:105
haddr_t getAddress() const noexcept
Retrieve the address of the object (within its file)
Definition: H5Object_misc.hpp:99
size_t getRefCount() const noexcept
Retrieve the number of references to this object.
Definition: H5Object_misc.hpp:102
H5O_info_t raw_info
Definition: H5Object.hpp:118
time_t getModificationTime() const noexcept
Retrieve the object's last modification time.
Definition: H5Object_misc.hpp:108
Definition: H5_definitions.hpp:15
ObjectType
Enum of the types of objects (H5O api)
Definition: H5Object.hpp:25