31 #include <agrum/tools/multidim/aggregators/forall.h> 35 namespace aggregator {
36 template <
typename GUM_SCALAR >
37 INLINE Forall< GUM_SCALAR >::Forall(Idx value) :
38 MultiDimAggregator< GUM_SCALAR >(), value__(value) {
39 GUM_CONSTRUCTOR(Forall);
42 template <
typename GUM_SCALAR >
43 INLINE Forall< GUM_SCALAR >::Forall(
const Forall< GUM_SCALAR >& from) :
44 MultiDimAggregator< GUM_SCALAR >(from) {
45 value__ = from.value__;
49 template <
typename GUM_SCALAR >
50 INLINE Forall< GUM_SCALAR >::~Forall() {
51 GUM_DESTRUCTOR(Forall);
54 template <
typename GUM_SCALAR >
55 INLINE Idx Forall< GUM_SCALAR >::neutralElt_()
const {
59 template <
typename GUM_SCALAR >
60 INLINE Idx Forall< GUM_SCALAR >::fold_(
const DiscreteVariable& v,
63 bool& stop_iteration)
const {
67 stop_iteration =
true;
72 template <
typename GUM_SCALAR >
76 Forall< GUM_SCALAR >::aggregatorName()
const {
78 ss <<
"forall[" << value__ <<
"]";
82 template <
typename GUM_SCALAR >
83 INLINE MultiDimContainer< GUM_SCALAR >*
84 Forall< GUM_SCALAR >::newFactory()
const {
85 return new Forall< GUM_SCALAR >(value__);