summaryrefslogtreecommitdiffstats
path: root/c++/src/H5DataType.cpp
diff options
context:
space:
mode:
authorBinh-Minh Ribler <bmribler@hdfgroup.org>2018-07-17 17:21:07 (GMT)
committerBinh-Minh Ribler <bmribler@hdfgroup.org>2018-07-17 17:21:07 (GMT)
commita31cd3623ff9493b7d6209efe23afcab84b05320 (patch)
tree215649251105b0a8be708f8fb746908ee93cf449 /c++/src/H5DataType.cpp
parent3aa24435180d10aeca6493f7c1b277cfd5c73fad (diff)
downloadhdf5-a31cd3623ff9493b7d6209efe23afcab84b05320.zip
hdf5-a31cd3623ff9493b7d6209efe23afcab84b05320.tar.gz
hdf5-a31cd3623ff9493b7d6209efe23afcab84b05320.tar.bz2
Fixed HDFFV-10472
Description: Added operator!= to DataType bool operator!=(const DataType& compared_type) Platforms tested: Linux/64 (jelly) Linux/32 (jam) Darwin (osx1010test)
Diffstat (limited to 'c++/src/H5DataType.cpp')
-rw-r--r--c++/src/H5DataType.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/c++/src/H5DataType.cpp b/c++/src/H5DataType.cpp
index e460871..28933dd 100644
--- a/c++/src/H5DataType.cpp
+++ b/c++/src/H5DataType.cpp
@@ -396,6 +396,20 @@ bool DataType::operator==(const DataType& compared_type) const
}
//--------------------------------------------------------------------------
+// Function: DataType::operator!=
+///\brief Compares this DataType against the given one to determines
+/// whether the two objects refer to different actual datatypes.
+///\param compared_type - IN: Reference to the datatype to compare
+///\return true if the datatypes are not equal, and false, otherwise.
+///\exception H5::DataTypeIException
+// July, 2018
+//--------------------------------------------------------------------------
+bool DataType::operator!=(const DataType& compared_type) const
+{
+ return !operator==(compared_type);
+}
+
+//--------------------------------------------------------------------------
// Function: DataType::p_commit (private)
//\brief Commits a transient datatype to a file, creating a new
// named datatype