49#ifndef GUM_MULTI_DIM_AGGREGATOR_H
50#define GUM_MULTI_DIM_AGGREGATOR_H
84 template <
typename GUM_ELEMENT >
154 virtual std::optional< Idx >
value()
const;
155 std::string
toString()
const override;
192 const std::string&
name()
const override;
230#ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
235 template <
typename GUM_ELEMENT >
Base class for discrete random variable.
Class for assigning/browsing values to tuples of discrete variables.
MultiDimContainer()
Default constructor.
MultiDimReadOnly()
Default constructor.
<agrum/base/multidim/aggregators/multiDimAggregator.h>
void setFirstNotification(const gum::Instantiation &) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
GUM_ELEMENT get(const Instantiation &i) const override
Adds a variable: the first one is the aggregator, the next ones are its parents.
void setChangeNotification(const gum::Instantiation &) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
bool isDecomposable() const
virtual Idx buildValue_(const gum::Instantiation &i) const =0
void setIncNotification(const gum::Instantiation &) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
void changeNotification(const gum::Instantiation &, const gum::DiscreteVariable *const, gum::Idx, gum::Idx) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
MultiDimAggregator()
Default constructor.
std::string toString() const override
Adds a variable: the first one is the aggregator, the next ones are its parents.
void setDecNotification(const gum::Instantiation &) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
void setLastNotification(const gum::Instantiation &) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
virtual std::optional< Idx > value() const
Returns the scalar parameter of this aggregator, if it has one.
Size realSize() const override
void add(const DiscreteVariable &v) override
Adds a variable: the first one is the aggregator, the next ones are its parents.
virtual std::string aggregatorName() const =0
Adds a variable: the first one is the aggregator, the next ones are its parents.
MultiDimContainer< GUM_ELEMENT > * newFactory() const override=0
This method creates a clone of this object, withouth its content (including variable),...
void copyFrom(const MultiDimContainer< GUM_ELEMENT > &src) const override
Copy of a multiDimICIModel.
const std::string & name() const override
Returns the real name of the multiDimArray.
MultiDimAggregator(const MultiDimAggregator< GUM_ELEMENT > &from)
Copy constructor.
bool decomposable_
decomposable_ indicates if the aggregator can be decomposed
virtual void checkVariable_(const DiscreteVariable &v) const
Checks that a variable can be added to this aggregator (nothing by default).
std::size_t Size
In aGrUM, hashed values are unsigned long int.
Size Idx
Type for indexes.
Header of the MultiDimReadOnly class.
Aggregators are functional description of CPTs.
std::ostream & operator<<(std::ostream &s, const MultiDimAggregator< GUM_ELEMENT > &ag)
For friendly displaying the content of the array.
template class GUM_SHARED_PUBLIC MultiDimAggregator< double >
gum is the global namespace for all aGrUM entities