... | ... |
@@ -47,8 +47,9 @@ |
47 | 47 |
typedef T Value; |
48 | 48 |
|
49 | 49 |
/// Returns the value associated with a key. |
50 | 50 |
|
51 |
/// Returns the value associated with a key. |
|
51 | 52 |
/// \bug Value shouldn't need to be default constructible. |
52 | 53 |
/// |
53 | 54 |
Value operator[](const Key &) const {return Value();} |
54 | 55 |
|
... | ... |
@@ -112,9 +113,9 @@ |
112 | 113 |
|
113 | 114 |
}; |
114 | 115 |
}; |
115 | 116 |
|
116 |
/// Read/ |
|
117 |
/// Read/writable map concept |
|
117 | 118 |
|
118 | 119 |
/// Read/writable map concept. |
119 | 120 |
/// |
120 | 121 |
template<typename K, typename T> |
... | ... |
@@ -145,8 +146,9 @@ |
145 | 146 |
/// Dereferable map concept |
146 | 147 |
|
147 | 148 |
/// Dereferable map concept. |
148 | 149 |
/// |
150 |
/// \todo Rethink this concept. |
|
149 | 151 |
template<typename K, typename T, typename R, typename CR> |
150 | 152 |
class ReferenceMap : public ReadWriteMap<K,T> |
151 | 153 |
{ |
152 | 154 |
public: |
... | ... |
@@ -164,16 +166,15 @@ |
164 | 166 |
protected: |
165 | 167 |
Value tmp; |
166 | 168 |
public: |
167 | 169 |
|
168 |
///Returns a reference to the value associated |
|
170 |
///Returns a reference to the value associated with a key. |
|
169 | 171 |
Reference operator[](const Key &) { return tmp; } |
170 |
///Returns a const reference to the value associated |
|
172 |
///Returns a const reference to the value associated with a key. |
|
171 | 173 |
ConstReference operator[](const Key &) const { return tmp; } |
172 | 174 |
/// Sets the value associated with a key. |
173 | 175 |
void set(const Key &k,const Value &t) { operator[](k)=t; } |
174 | 176 |
|
175 |
/// \todo Rethink this concept. |
|
176 | 177 |
template<typename _ReferenceMap> |
177 | 178 |
struct ReferenceMapConcept { |
178 | 179 |
|
179 | 180 |
void constraints() { |
0 comments (0 inline)