summaryrefslogtreecommitdiffstats
path: root/c++/src/H5Location.h
Commit message (Collapse)AuthorAgeFilesLines
* Adding new C++ wrappersBinh-Minh Ribler2017-10-051-30/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Description: - Added wrappers for H5Tencode to class DataType and H5Tdecode to classes DataType and its subclasses. // Creates a binary object description of this datatype. void DataType::encode() // Returns the decoded type from the binary object description. virtual DataType* DataType::decode() const; virtual DataType* ArrayType::decode() const; virtual DataType* CompType::decode() const; virtual DataType* DataType::decode() const; virtual DataType* EnumType::decode() const; virtual DataType* FloatType::decode() const; virtual DataType* IntType::decode() const; virtual DataType* StrType::decode() const; virtual DataType* VarLenType::decode() const; - Replaced existing functions CommonFG::openXxxType with individual data type constructors, XxxType, to improve usability. Platforms tested: Linux/32 2.6 (jam) Linux/64 (platypus) Darwin (osx1010test)
* Merge pull request #537 in HDFFV/hdf5 from ~LRKNOX/hdf5_lrk:hdf5_1_8 to hdf5_1_8Larry Knox2017-05-251-6/+4
|\ | | | | | | | | | | | | * commit '2fb535ceff613dfd2a02b5b78ba7c3b5df95424b': Remove The HDF Group copyright header from 3rd party file. Remove java/COPYING file - no java directory in this branch. Update text in COPYING files in subdirectories to match changes to copyright notices in source files. Update Copyright notices in acsite.m4 and bin/yodconfigure that were overlooked by chkcopyright. Remove broken and unnecessary urls from comments in hl/fortran/src/H5IMcc.c and hl/src/H5IM.c. Commit bin/reconfigure changes to generated files. Change copyright headers to replace url referring to file to be removed and replace it with new url for COPYING file.
| * Change copyright headers to replace url referring to file to belrknox2017-05-161-6/+4
| | | | | | | | removed and replace it with new url for COPYING file.
* | Purpose: Add new C++ wrappers (HDFFV-10156)Binh-Minh Ribler2017-05-181-0/+10
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Description: Added wrappers for H5Iis_valid, H5Ps/get_nlinks, H5Tget_create_plist, H5Oopen, and H5Oclose // Checks if the given ID is valid. static bool isValid(hid_t an_id); // Sets the number of soft or user-defined links that can be // traversed before a failure occurs. void setNumLinks(size_t nlinks) const; // Gets the number of soft or user-defined link traversals allowed size_t getNumLinks() const; // Returns a copy of the creation property list of a datatype. PropList getCreatePlist() const; // Opens an object within a group or a file, i.e., root group. hid_t openObjId(const char* name,...); hid_t openObjId(const H5std_string& name,...); // Closes an object opened by getObjId(). void closeObjId(hid_t obj_id) const; // Gets general information about this file. void getFileInfo(H5F_info2_t& file_info) const; Platforms tested: Linux/32 2.6 (jam) Linux/64 (platypus) Darwin (osx1010test)
* Add H5Lexists wrappersBinh-Minh Ribler2017-05-131-0/+4
| | | | | | | | | | | Description: Added wrappers H5Location::exists() for H5Lexists. Added new class LinkAccPropList to be used by H5Location::exists() Rearranged source files in Makefile.am Platforms tested: Linux/32 2.6 (jam) Linux/64 (platypus) Darwin (osx1010test)
* Improvement of class hierarchyBinh-Minh Ribler2017-05-101-22/+25
| | | | | | | | | | | | | | Description: - Moved class Attribute to be derived from class H5Location instead of IdComponent because an attribute id can be used as loc_id in C APIs. - Copied wrappers of H5A APIs in H5Location into H5Object because H5A functions do not take an attribute id as loc_id. The original wrappers will be deprecated in future releases. - Revised comments Platforms tested: Linux/32 2.6 (jam) Linux/64 (platypus) Darwin (osx1010test)
* Code improvementBinh-Minh Ribler2017-05-081-11/+6
| | | | | | | | | | | | Description: - Moved class H5File to inherit from class Group because an HDF5 file is a root group - Cleanup header file inclusion and class forward declaration - Revised comments Platforms tested: Linux/32 2.6 (jam) Linux/64 (platypus) Darwin (osx1010test)
* Format changes only.Binh-Minh Ribler2017-04-231-7/+7
| | | | | Platforms tested: Linux/32 2.6 (jam) - very minor
* Miscellaneous clean-up: format and commentsBinh-Minh Ribler2017-04-131-2/+11
| | | | | Platforms tested: Linux/64 (jelly) - very minor
* Description:Binh-Minh Ribler2017-04-111-99/+99
| | | | | | Only format changes: mostly tabs vs. spaces Platforms tested: Linux/64 (jelly)
* Purpose: Fix HDFFV-9532Binh-Minh Ribler2016-10-231-4/+0
| | | | | | | | | | | | | Description: Removed obsolete macros from C++ API library and tests: H5_NO_NAMESPACE and __cplusplus Leave OLD_HEADER_FILENAME because iostream.h might still be in use, until further checking is done. Leave H5_NO_STD to consider retiring H5std_string first. Platforms tested: Linux/32 2.6 (jam) Linux/64 (jelly) Darwin (osx1010test)
* [svn-r28052] Purpose: Fix memory leaksBinh-Minh Ribler2015-10-131-3/+0
| | | | | | | | | | | | | Description: - Implemented the friend function void f_PropList_setId(PropList* plist, hid_t new_id) to work around the same problem described in trunk r26655, for the API DataSet::getCreatePlist() - Cleaned up some comments and obsolete functions Merged from trunk r28047 Platforms tested: Linux/32 2.6 (jam) Darwin (osx1010test)
* [svn-r26731] Purpose: Fixed HDFFV-7947Binh-Minh Ribler2015-04-061-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Description: When copy constructor or constructor that takes an existing id is invoked, the C ref counter stays the same but there is an extra C++ object which later is destroyed and may cause the HDF5 id to be closed prematurely. The C++ library needs to increment the ref counter in these situations, so that the C library will not close the id when it is still being referenced. However, the incrementing of ref count left some objects opened at the end of the program, perhaps, due to compiler's optimization on cons/destructors. The constructor, that takes an existing id, needs to increment the counter but it seems that the matching destructor wasn't invoked. The workaround is to have a function for each class that has "id" that only sets the id and not increment the ref count for the library to use in these situations. These functions are "friend" and not public. The friend functions are: void f_Attribute_setId(Attribute *, hid_t) void f_DataSet_setId(DataSet *, hid_t) void f_DataSpace_setId(DataSpace *, hid_t) void f_DataType_setId(DataType *, hid_t) Merged from trunk: r26655 Platforms tested: Linux/64 (platypus) Linux/32 2.6 (jam Intel 15.0) SunOS 5.11 (emu)
* [svn-r26729] Purpose: Fix bugsBinh-Minh Ribler2015-04-051-1/+1
| | | | | | | | | | | | | | | | | | | | Description: - Changed DataType::operator= to simply copy the id of rhs instead of calling H5Tcopy because, when the operator= is invoked, a different datatype id is created and it won't have the same characteristics as rhs', specifically, if the rhs represents a named datatype, "this" would still be a transient datatype. - Added a DataType constructor that takes a PredType object, and this constructor will cause H5Tcopy to generate another datatype id, from a predefined datatype. - Fixed various mistakes in tests. - Fixed typo that caused failure on Windows. Merged from trunk r26640 and r26462 Platforms tested: Linux/64 (platypus) Linux/32 2.6 (jam/gnu and jam/icc 15) SunOS 5.11 (emu)
* [svn-r26726] Purpose: Fix warnings HDFFV-8658Binh-Minh Ribler2015-04-041-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | Description: (r26457) The following two constructors of classes: AbstractDs, IdComponent, H5Location, and H5Object are no longer appropriate after the data member "id" had been moved from IdComponent to the sub-classes. The copy constructors are noop and will be generated by the compilers if needed so they can be removed in 1.8.15 without effecting applications. The other constructors will be removed from 1.10 release, and then from 1.8 if their removal does not raise any problems in at least two 1.10 releases. <Classname>(const hid_t h5_id); <Classname>(const <Classname>& original); Deprecation warnings are added to each of these classes. The other classes are changed to call the default constructor instead of one of the constructors above. Platforms tested: Linux/64 (platypus) Linux/32 2.6 (jam) SunOS 5.11 (emu)
* [svn-r25030] Purpose: Fix HDFFV-8658Binh-Minh Ribler2014-04-121-3/+3
| | | | | | | | | | Description: Turned on warnings and removed some of those. (merged from trunk-r24994) Platforms tested: Linux/ppc64 (ostrich) Linux/32 2.6 (jam) SunOS 5.11 (emu)
* [svn-r24902] Description:Binh-Minh Ribler2014-03-261-2/+2
| | | | | | | | | Fixed mismatched function prototype/definition that caused daily test failure on emu/production/HDF5TestExpress=1. Platforms tested: Linux/ppc64 (ostrich) Linux/32 2.6 (jam) SunOS 5.11 (emu)
* [svn-r24870] Description:Binh-Minh Ribler2014-03-231-2/+3
| | | | | | | | | | | | | | | - Added another overload for char* argument: ssize_t getComment(const char* name, const size_t buf_size, char* comment) - Changed default value to 0 for the other two getComment methods - Added HDmemset to after every char string allocation to clear the buffer - Added a null terminator to the comment returned from the C call, in getComment methods - Some minor cleanup Merged from trunk: -r24865 -r24867 Platforms tested: Linux/ppc64 (ostrich) Linux/32 2.6 (jam) SunOS 5.11 (emu)
* [svn-r24290] Description:Binh-Minh Ribler2013-10-141-7/+10
| | | | | | | | | - Added a lot of documentation to classes for Reference Manual. - Fixed some format inconsistencies Platforms tested: Linux/ppc64 (ostrich) Linux/32 2.6 (jam) Linux/64 2.6 (koala)/PGI compilers
* [svn-r24216] Purpose: Merged changes from trunkBinh-Minh Ribler2013-09-291-0/+167
Description from trunk, r22836 In this bug, H5File doesn't have the ability to create attribute. The following changes will provide that functionality and several others that were also missing: - Added an abstract class H5Location in between IdComponent and H5Object. - New class structure of IdComponent, H5Location, H5Object, H5File IdComponent | H5Location / \ H5Object H5File - Wrappers in H5Object were moved to H5Location because the related C functions take either file, group, dataset, or named datatype ID. - Added wrapper for H5Rget_obj_type2 - Added tests for file attributes and H5Rget_obj_type2 wrapper Description from trunk, r22845 Fixed miscellaneous inconsistencies and typos, which also took care of the failure in Packet Table test on daily test today. Description from trunk, r24143 Fixed comments, documentation, and mis-matched DOXYGEN_SHOULD_SKIP_THIS pairs. Description from trunk, r24188 - The failure in daily test was caused by missing initialization of member "id" in a few constructors. This is now fixed. - Added two overloaded H5Location::setComment - Improved some error reporting in H5Location - Improved error reporting in tests Description from trunk, r24189 Changed header guards from single underscore to double underscore. Platforms tested: SunOS 5.11 (emu) Linux/32 2.6 (jam) Linux/64 2.6 (koala)/PGI compilers