29 #ifndef GUM_VARIABLE_NODE_MAP_H 30 #define GUM_VARIABLE_NODE_MAP_H 178 #ifndef GUM_NO_INLINE Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
void __copy(const VariableNodeMap &source)
effectively do the copy (for copy constructor or operator=)
const std::string & name(NodeId id) const
Returns the name of a variable given its id.
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Bijection< NodeId, const DiscreteVariable *> __nodes2vars
Bijection between the node's NodeIds and the variables.
NodeId insert(NodeId id, const DiscreteVariable &var)
Maps id with var.
VariableNodeMap()
Default constructor.
Container used to map discrete variables with nodes.
bool exists(NodeId id) const
Return true if id matches a node.
Base class for discrete random variable.
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
void erase(NodeId id)
Removes a var and it's id of this mapping. The pointer is deleted.
std::ostream & operator<<(std::ostream &output, const BayesNet< GUM_SCALAR > &bn)
Prints map's DAG in output using the Graphviz-dot format.
void clear()
removes all the associations
const DiscreteVariable & operator[](NodeId id) const
Returns a discrete variable given it's node id.
Set of pairs of elements with fast search for both elements.
NodeId idFromName(const std::string &name) const
void changeName(NodeId id, const std::string &new_name)
we allow the user to change the name of a variable
VariableNodeMap & operator=(const VariableNodeMap &source)
Copy operator.
const std::string toString() const
friendly displays the content of the VariableNodeMap
Bijection< std::string, NodeId > __names2nodes
HashTable for easely find an id from a name.
~VariableNodeMap()
Destructor.
const DiscreteVariable & variableFromName(const std::string &name) const
Size NodeId
Type for node ids.
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.