aGrUM  0.16.0
LpInterface_inl.h
Go to the documentation of this file.
1 
30 #include <agrum/CN/LpInterface.h>
31 
32 #ifndef DOXYGEN_SHOULD_SKIP_THIS
33 
34 namespace gum {
35 
36  INLINE Size
37  HashFunc< credal::lp::LpCol >::castToSize(const credal::lp::LpCol& key) {
38  return Size(key.id());
39  }
40 
41  INLINE Size HashFunc< credal::lp::LpCol >::
42  operator()(const credal::lp::LpCol& key) const {
43  return (castToSize(key) * gum::HashFuncConst::gold) & this->_hash_mask;
44  }
45 
46 } /* namespace gum */
47 
48 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
static constexpr Size gold
Definition: hashFunc.h:76
static Size castToSize(const credal::lp::LpCol &key)
Returns the value of a key as a Size.
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.
Definition: agrum.h:25
std::size_t Size
In aGrUM, hashed values are unsigned long int.
Definition: types.h:48