All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
List of all members | Public Types | Public Member Functions | Related Functions
TrueMap< K > Class Template Reference

Detailed Description

template<typename K>
class lemon::TrueMap< K >

This read-only map assigns true to each key.

Note that

TrueMap<K> tm;

is equivalent to

ConstMap<K,bool> tm(true);
See Also
FalseMap
ConstMap

#include <lemon/maps.h>

+ Inheritance diagram for TrueMap< K >:

Public Types

typedef K Key
 
 
typedef bool Value
 
 
- Public Types inherited from MapBase< K, bool >
typedef K Key
 The key type of the map.
 
typedef bool Value
 The value type of the map. (The type of objects associated with the keys).
 

Public Member Functions

Value operator[] (const Key &) const
 Gives back true.
 

Related Functions

(Note that these are not member functions.)

template<typename K >
TrueMap< K > trueMap ()
 Returns a TrueMap class.