Generic inf accumulator class. More...
#include <inf.hh>
Public Types | |
typedef T | argument |
typedef Accumulator< void > | category |
typedef inf< T > | exact_t |
typedef const T & | q_result |
typedef mln::metal::unqualif < const T & >::ret | result |
Public Member Functions | |
inf () | |
bool | is_valid () const |
Check whether this accu is able to return a result. | |
const T & | subj_ () |
void | take_as_init (const T &t) |
Take as initialization the value t . | |
void | take_as_init_ (const T &t) |
Default implementation of "take as initialization". | |
void | take_n_times (unsigned n, const T &t) |
Take n times the value t . | |
void | take_n_times_ (unsigned n, const T &t) |
Default implementation of "take n times". | |
const T & | to_result () const |
Get the value of the accumulator. | |
void | init () |
Manipulators. | |
void | take_as_init_ (const argument &t) |
void | take (const argument &t) |
void | take (const inf< T > &other) |
Protected Attributes | |
mln::fun::inf::with< T, T >::ret | fun_ |
T | t_ |
Generic inf accumulator class.
The parameter T
is the type of values.
typedef T mln::accu::math::inf< T >::argument |
typedef Accumulator<void> mln::Accumulator< inf< T > >::category [inherited] |
Reimplemented from mln::Proxy< inf< T > >.
typedef inf< T > mln::Object< inf< T > >::exact_t [inherited] |
typedef const T & mln::accu::internal::base< const T & , inf< T > >::q_result [inherited] |
typedef mln::metal::unqualif< const T & >::ret mln::accu::internal::base< const T & , inf< T > >::result [inherited] |
mln::accu::math::inf< T >::inf | ( | ) | [inline] |
References mln::accu::math::inf< T >::init().
void mln::accu::math::inf< T >::init | ( | ) | [inline] |
Manipulators.
References mln::accu::math::inf< T >::t_.
Referenced by mln::accu::math::inf< T >::inf().
bool mln::accu::math::inf< T >::is_valid | ( | ) | const [inline] |
Check whether this accu is able to return a result.
Always true here.
const T & mln::accu::internal::base< const T & , inf< T > >::subj_ | ( | ) | [inherited] |
void mln::accu::math::inf< T >::take | ( | const inf< T > & | other | ) | [inline] |
References mln::accu::math::inf< T >::fun_, and mln::accu::math::inf< T >::t_.
void mln::accu::math::inf< T >::take | ( | const argument & | t | ) | [inline] |
References mln::accu::math::inf< T >::fun_, and mln::accu::math::inf< T >::t_.
void mln::Accumulator< inf< T > >::take_as_init | ( | const T & | t | ) | [inherited] |
Take as initialization the value t
.
Dev note: this is a final method; override if needed by take_as_init_ (ending with '_').
void mln::Accumulator< inf< T > >::take_as_init_ | ( | const T & | t | ) | [inherited] |
Default implementation of "take as initialization".
void mln::accu::math::inf< T >::take_as_init_ | ( | const argument & | t | ) | [inline] |
References mln::accu::math::inf< T >::t_.
void mln::Accumulator< inf< T > >::take_n_times | ( | unsigned | n, | |
const T & | t | |||
) | [inherited] |
Take n
times the value t
.
Dev note: this is a final method; override if needed by take_as_init_ (ending with '_').
void mln::Accumulator< inf< T > >::take_n_times_ | ( | unsigned | n, | |
const T & | t | |||
) | [inherited] |
Default implementation of "take n times".
const T & mln::accu::math::inf< T >::to_result | ( | ) | const [inline] |
Get the value of the accumulator.
References mln::accu::math::inf< T >::t_.
mln::fun::inf::with<T, T>::ret mln::accu::math::inf< T >::fun_ [protected] |
Referenced by mln::accu::math::inf< T >::take().
T mln::accu::math::inf< T >::t_ [protected] |