summaryrefslogtreecommitdiff
path: root/include/value.h
diff options
context:
space:
mode:
authorEmiel Bruijntjes <emiel.bruijntjes@copernica.com>2014-03-06 17:05:19 +0100
committerEmiel Bruijntjes <emiel.bruijntjes@copernica.com>2014-03-06 17:05:19 +0100
commite48382d539bddf4c57542e2a12c4a8ddec69d0b6 (patch)
tree7702b8be03e33bc6661e0eb294636aae20f32a50 /include/value.h
parent62f743b7f7dff333d999f3070a52f2874dcd9488 (diff)
changes to documentation, comparison operators added to Value class
Diffstat (limited to 'include/value.h')
-rw-r--r--include/value.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/value.h b/include/value.h
index b732616..7615997 100644
--- a/include/value.h
+++ b/include/value.h
@@ -263,6 +263,17 @@ public:
Value operator%(double value);
/**
+ * Comparison operators
+ * @param value
+ */
+ template <typename T> bool operator==(const T &value) const { return (T)*this == value; }
+ template <typename T> bool operator!=(const T &value) const { return (T)*this == value; }
+ template <typename T> bool operator<=(const T &value) const { return (T)*this == value; }
+ template <typename T> bool operator>=(const T &value) const { return (T)*this == value; }
+ template <typename T> bool operator< (const T &value) const { return (T)*this == value; }
+ template <typename T> bool operator> (const T &value) const { return (T)*this == value; }
+
+ /**
* The type of object
* @return Type
*/