diff -r ad483acf1654 -r 6a2a33ad261b lemon/circulation.h --- a/lemon/circulation.h Tue Dec 02 15:33:22 2008 +0000 +++ b/lemon/circulation.h Fri Dec 05 00:22:47 2008 +0100 @@ -419,7 +419,7 @@ /// /// \pre Either \ref run() or \ref init() must be called before /// using this function. - const Elevator& elevator() { + const Elevator& elevator() const { return *_level; } @@ -644,7 +644,7 @@ /// /// \pre Either \ref run() or \ref init() must be called before /// using this function. - const FlowMap& flowMap() { + const FlowMap& flowMap() const { return *_flow; } @@ -669,7 +669,7 @@ \sa barrierMap() \sa checkBarrier() */ - bool barrier(const Node& node) + bool barrier(const Node& node) const { return (*_level)[node] >= _el; } @@ -692,7 +692,7 @@ /// \sa barrier() /// \sa checkBarrier() template - void barrierMap(BarrierMap &bar) + void barrierMap(BarrierMap &bar) const { for(NodeIt n(_g);n!=INVALID;++n) bar.set(n, (*_level)[n] >= _el); @@ -712,7 +712,7 @@ ///Check if the found flow is a feasible circulation, /// - bool checkFlow() { + bool checkFlow() const { for(ArcIt e(_g);e!=INVALID;++e) if((*_flow)[e]<(*_lo)[e]||(*_flow)[e]>(*_up)[e]) return false; for(NodeIt n(_g);n!=INVALID;++n) @@ -730,7 +730,7 @@ ///Check whether or not the last execution provides a barrier. ///\sa barrier() ///\sa barrierMap() - bool checkBarrier() + bool checkBarrier() const { Value delta=0; for(NodeIt n(_g);n!=INVALID;++n)