
URL: https://svn.lrde.epita.fr/svn/oln/trunk/milena ChangeLog: 2009-05-26 Edwin Carlinet <carlinet@lrde.epita.fr> Add getters to base and current level to height attribute. * mln/morpho/attribute/height.hh: Add base and current level getters. --- height.hh | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) Index: trunk/milena/mln/morpho/attribute/height.hh =================================================================== --- trunk/milena/mln/morpho/attribute/height.hh (revision 3873) +++ trunk/milena/mln/morpho/attribute/height.hh (revision 3874) @@ -104,6 +104,10 @@ /// Get the value of the accumulator. unsigned to_result() const; + /// Get base & current level of the accumulator. + unsigned base_level() const; + unsigned current_level() const; + protected: /// The reference level in the component. @@ -209,6 +213,23 @@ template <typename I> inline + unsigned + height<I>::base_level() const + { + return ref_; + } + + template <typename I> + inline + unsigned + height<I>::current_level() const + { + return cur_; + } + + + template <typename I> + inline bool height<I>::is_valid() const {