ShiftMap
Declared in lemon/maps.h, in the group Map Adaptors; the same class on the Doxygen site.
-
template< typename M , typename C = typename M::Value >
class ShiftMap : public MapBase< M::Key , M::Value > Shifts a map with a constant.
This read-only map returns the sum of the given map and a constant value (i.e. it shifts the map with the constant). Its
KeyandValueare inherited fromM.Actually,
is equivalent toShiftMap< M > sh( m , v );
ConstMap< M::Key , M::Value > cm( v ); AddMap< M , ConstMap< M::Key , M::Value > > sh( m , cm );
The simplest way of using this map is through the shiftMap() function.
See also