diff options
author | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2009-10-20 19:59:43 (GMT) |
---|---|---|
committer | Binh-Minh Ribler <bmribler@hdfgroup.org> | 2009-10-20 19:59:43 (GMT) |
commit | cdf49b647234933fca0ee7cbed83591fe6858f6f (patch) | |
tree | 8fed3a36c26e650000eb650165ea4c0a8afb72bc /c++/src/H5CommonFG.h | |
parent | e91af4bdbdab77fd5b640a8318adbd3f390325ea (diff) | |
download | hdf5-cdf49b647234933fca0ee7cbed83591fe6858f6f.zip hdf5-cdf49b647234933fca0ee7cbed83591fe6858f6f.tar.gz hdf5-cdf49b647234933fca0ee7cbed83591fe6858f6f.tar.bz2 |
[svn-r17695] Purpose: Code improvement
Description:
Fixed CommonFG::getComment and CommonFG::getLinkval to provide
default values for buffer size to improve usability.
Added test file tlinks.cpp, which only contains test for getLinkval
and will expand when C++ wrappers for H5L functions are implemented.
Platforms tested:
Linux/32 2.6 (jam)
FreeBSD/64 6.3 (liberty)
Diffstat (limited to 'c++/src/H5CommonFG.h')
-rw-r--r-- | c++/src/H5CommonFG.h | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/c++/src/H5CommonFG.h b/c++/src/H5CommonFG.h index 87c0615..d472d42 100644 --- a/c++/src/H5CommonFG.h +++ b/c++/src/H5CommonFG.h @@ -50,9 +50,8 @@ class H5_DLLCPP CommonFG { DataSet openDataSet(const H5std_string& name) const; // Retrieves comment for the HDF5 object specified by its name. - H5std_string getComment(const H5std_string& name) const; - H5std_string getComment(const char* name, size_t bufsize) const; - H5std_string getComment(const H5std_string& name, size_t bufsize) const; + H5std_string getComment(const char* name, size_t bufsize=256) const; + H5std_string getComment(const H5std_string& name, size_t bufsize=256) const; // Removes the comment for the HDF5 object specified by its name. void removeComment(const char* name) const; @@ -62,9 +61,9 @@ class H5_DLLCPP CommonFG { void setComment(const char* name, const char* comment) const; void setComment(const H5std_string& name, const H5std_string& comment) const; - // Returns the name of the HDF5 object that the symbolic link points to. - H5std_string getLinkval(const char* name, size_t size) const; - H5std_string getLinkval(const H5std_string& name, size_t size) const; + // Returns the value of a symbolic link. + H5std_string getLinkval(const char* link_name, size_t size=0) const; + H5std_string getLinkval(const H5std_string& link_name, size_t size=0) const; // Returns the number of objects in this group. hsize_t getNumObjs() const; |