Index: lemon/maps.h
===================================================================
--- lemon/maps.h (revision 1439)
+++ lemon/maps.h (revision 1456)
@@ -147,7 +147,11 @@
public:
+ ///\e
typedef K Key;
+ ///\e
typedef T Value;
+ ///\e
typedef T& Reference;
+ ///\e
typedef const T& ConstReference;
@@ -227,5 +231,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M::Key Key;
+ ///\e
typedef T Value;
@@ -272,5 +278,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M1::Key Key;
+ ///\e
typedef typename M1::Value Value;
@@ -319,5 +327,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M::Key Key;
+ ///\e
typedef typename M::Value Value;
@@ -357,5 +367,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M1::Key Key;
+ ///\e
typedef typename M1::Value Value;
@@ -395,5 +407,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M1::Key Key;
+ ///\e
typedef typename M1::Value Value;
@@ -439,5 +453,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M::Key Key;
+ ///\e
typedef typename M::Value Value;
@@ -477,5 +493,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M1::Key Key;
+ ///\e
typedef typename M1::Value Value;
@@ -523,5 +541,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M2::Key Key;
+ ///\e
typedef typename M1::Value Value;
@@ -576,5 +596,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M1::Key Key;
+ ///\e
typedef V Value;
@@ -625,5 +647,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M::Key Key;
+ ///\e
typedef typename M::Value Value;
@@ -677,5 +701,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M::Key Key;
+ ///\e
typedef typename M::Value Value;
@@ -718,5 +744,7 @@
typedef True NeedCopy;
+ ///\e
typedef K Key;
+ ///\e
typedef V Value;
@@ -757,7 +785,11 @@
typedef True NeedCopy;
+ ///\e
typedef typename M::Key argument_type;
+ ///\e
typedef typename M::Value result_type;
+ ///\e
typedef typename M::Key Key;
+ ///\e
typedef typename M::Value Value;
@@ -807,5 +839,7 @@
typedef True NeedCopy;
+ ///\e
typedef typename M1::Key Key;
+ ///\e
typedef typename M1::Value Value;
@@ -832,8 +866,58 @@
}
+
+
+ /* ************* BOOL MAPS ******************* */
+
+ ///Logical 'not' of a map
+
+ ///This bool \ref concept::ReadMap "read only map" returns the
+ ///logical negation of
+ ///value returned by the
+ ///given map. Its \c Key and will be inherited from \c M,
+ ///its Value is bool.
+
+ template
+ class NotMap
+ {
+ typename SmartConstReference::Type m;
+ public:
+
+ typedef True NeedCopy;
+ ///\e
+ typedef typename M::Key Key;
+ ///\e
+ typedef bool Value;
+
+ ///Constructor
+
+ ///\e
+ ///
+ NotMap(const M &_m) : m(_m) {};
+ Value operator[](Key k) const {return !m[k];}
+ };
+
+ ///Returns a \ref NotMap class
+
+ ///This function just returns a \ref NotMap class.
+ ///\relates NotMap
+ template
+ inline NotMap notMap(const M &m)
+ {
+ return NotMap(m);
+ }
+
+
+
+
+
+
+
+
+
+
+
/// @}
-
}
-
#endif // LEMON_MAPS_H