aGrUM  0.16.0
min.h
Go to the documentation of this file.
1 
30 #ifndef GUM_MIN_AGGREGATOR_H
31 #define GUM_MIN_AGGREGATOR_H
32 
34 
35 namespace gum {
36 
37  namespace aggregator {
38 
39  // =========================================================================
40  // === GUM_MIN_AGGREGATOR ===
41  // =========================================================================
42 
52  template < typename GUM_SCALAR >
53  class Min : public MultiDimAggregator< GUM_SCALAR > {
54  public:
55  Min();
56  Min(const Min< GUM_SCALAR >& from);
57  virtual ~Min();
58 
77 
78  virtual std::string aggregatorName() const;
79 
80  protected:
81  virtual Idx _neutralElt() const;
82  virtual Idx _fold(const DiscreteVariable& v,
83  Idx i1,
84  Idx i2,
85  bool& stop_iteration) const;
86  };
87 
88 
89 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
90  extern template class Min< double >;
91 #endif
92 
93 
94  } // namespace aggregator
95 } // namespace gum
96 
98 
99 #endif // GUM_MIN_AGGREGATOR_H
Base class for discrete random variable.
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Definition: agrum.h:25
Abstract base class for all multi dimensionnal containers.
<agrum/multidim/aggregators/multiDimAggregator.h>
virtual Idx _neutralElt() const
_neutralElt() is the result value for the first application of _fold
Definition: min_tpl.h:58
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
virtual ~Min()
Definition: min_tpl.h:53
virtual std::string aggregatorName() const
Definition: min_tpl.h:71
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Size Idx
Type for indexes.
Definition: types.h:53
virtual Idx _fold(const DiscreteVariable &v, Idx i1, Idx i2, bool &stop_iteration) const
_fold is applied on value i1 for variable v. the actual result for precedent applications is i2...
Definition: min_tpl.h:63
min aggregator
Definition: min.h:53
virtual MultiDimContainer< GUM_SCALAR > * newFactory() const
This method creates a clone of this object, withouth its content (including variable), you must use this method if you want to ensure that the generated object has the same type than the object containing the called newFactory()
Definition: min_tpl.h:76