equal
deleted
inserted
replaced
379 ///Constructor |
379 ///Constructor |
380 |
380 |
381 ///Constructor |
381 ///Constructor |
382 ///\param _m is the undelying map |
382 ///\param _m is the undelying map |
383 ///\param _v is the shift value |
383 ///\param _v is the shift value |
384 ShiftWriteMap(const M &_m, const C &_v ) : m(_m), v(_v) {}; |
384 ShiftWriteMap(M &_m, const C &_v ) : m(_m), v(_v) {}; |
385 Value operator[](Key k) const {return m[k] + v;} |
385 Value operator[](Key k) const {return m[k] + v;} |
386 void set(Key k, const Value& c) { m.set(k, c - v); } |
386 void set(Key k, const Value& c) { m.set(k, c - v); } |
387 }; |
387 }; |
388 |
388 |
389 ///Returns an \ref ShiftMap class |
389 ///Returns an \ref ShiftMap class |