diff options
author | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2019-03-20 19:07:40 (GMT) |
---|---|---|
committer | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2019-03-20 19:07:40 (GMT) |
commit | 222346f3732ba3bfb007da410e1b808be129aaaf (patch) | |
tree | 061d33723552465bbb3b672bfff10e4fe6bc2b96 /c++/src/H5Object.h | |
parent | 7add52ff4f2443357648d53d52add274d1b18b5f (diff) | |
parent | 604b67df19a164824b74fba0aa5e489b5a64d1ae (diff) | |
download | hdf5-222346f3732ba3bfb007da410e1b808be129aaaf.zip hdf5-222346f3732ba3bfb007da410e1b808be129aaaf.tar.gz hdf5-222346f3732ba3bfb007da410e1b808be129aaaf.tar.bz2 |
Merge branch 'develop' of https://bitbucket.hdfgroup.org/scm/~bmribler/hdf5_bmr_fixbug into develop
Diffstat (limited to 'c++/src/H5Object.h')
-rw-r--r-- | c++/src/H5Object.h | 26 |
1 files changed, 22 insertions, 4 deletions
diff --git a/c++/src/H5Object.h b/c++/src/H5Object.h index 10b3865..4a4e909 100644 --- a/c++/src/H5Object.h +++ b/c++/src/H5Object.h @@ -40,16 +40,30 @@ namespace H5 { // Inheritance: H5Location -> IdComponent // Define the operator function pointer for H5Aiterate(). -typedef void (*attr_operator_t)(H5Object& loc/*in*/, - const H5std_string attr_name/*in*/, - void *operator_data/*in,out*/); +typedef void (*attr_operator_t)(H5Object& loc, + const H5std_string attr_name, + void *operator_data); + +// Define the operator function pointer for H5Ovisit2(). +typedef int (*visit_operator_t)(H5Object& obj, + const H5std_string attr_name, + const H5O_info_t *oinfo, + void *operator_data); // User data for attribute iteration class UserData4Aiterate { public: attr_operator_t op; void* opData; - H5Object* location; + H5Object* location; // Consider changing to H5Location +}; + +// User data for visit iteration +class UserData4Visit { + public: + visit_operator_t op; + void* opData; + H5Object* obj; }; class H5_DLLCPP H5Object : public H5Location { @@ -71,6 +85,9 @@ class H5_DLLCPP H5Object : public H5Location { // Iterate user's function over the attributes of this object. int iterateAttrs(attr_operator_t user_op, unsigned* idx = NULL, void* op_data = NULL); + // Recursively visit elements reachable from this object. + void visit(H5_index_t idx_type, H5_iter_order_t order, visit_operator_t user_op, void *op_data, unsigned int fields); + // Returns the object header version of an object unsigned objVersion() const; @@ -98,6 +115,7 @@ class H5_DLLCPP H5Object : public H5Location { ssize_t getObjName(H5std_string& obj_name, size_t len = 0) const; H5std_string getObjName() const; + #ifndef DOXYGEN_SHOULD_SKIP_THIS protected: |