![]() |
Elm
2
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
|
#include <elm/delegate.h>
Public Types | |
typedef StrictMapDelegate< C > | self_t |
typedef C::key_t | key_t |
typedef C::val_t | val_t |
Public Member Functions | |
StrictMapDelegate (C &map, const key_t &key) | |
val_t | get (void) const |
void | put (const val_t &val) |
operator val_t (void) const | |
val_t | operator* (void) const |
self_t & | operator= (const val_t &val) |
Delegate class to access functions get/put() of map using the overload of [i] operators. In the opposite to MapDelegate, this class throws a KeyException if the key of a read item does not exist.
A common use of this delegate in a class implementing a mutable map:
T | Type of map element values. |
typedef C::key_t key_t |
typedef StrictMapDelegate<C> self_t |
typedef C::val_t val_t |
|
inline |
References Option< T >::isNone().
Referenced by StrictMapDelegate< C >::operator val_t(), and StrictMapDelegate< C >::operator*().
References StrictMapDelegate< C >::get().
References StrictMapDelegate< C >::get().
References StrictMapDelegate< C >::put().
Referenced by StrictMapDelegate< C >::operator=().