This struct condenses N boolean values into roughly N bits, saving roughly 4x memory. NUM_ELEMS parameter takes in the number of boolean values. BASE_INDEX parameter takes in the index of the first value. The recommended way to use this struct is with an enum. See core::scoring::hbonds::graph::AtomInfo for an example.
More...
|
| DenseBoolMap () |
|
void | set (unsigned int const element, bool const setting) |
|
template<unsigned int const element> |
void | set (bool const setting) |
| templated equivalent to set( element, setting ). I personally like this one better because it does bounds-checking at compile time and not just in debug mode. Of course, this only works if you know the value for "element" when calling set(). More...
|
|
bool | get (unsigned int const element) const |
|
template<unsigned int const element> |
constexpr bool | get () const |
| templated equivalent to get( element ). I personally like this one better because it does bounds-checking at compile time and not just in debug mode. Of course, this only works if you know the value for "element" when calling get(). More...
|
|
template<unsigned int NUM_ELEMS, unsigned int BASE_INDEX>
struct utility::DenseBoolMap< NUM_ELEMS, BASE_INDEX >
This struct condenses N boolean values into roughly N bits, saving roughly 4x memory. NUM_ELEMS parameter takes in the number of boolean values. BASE_INDEX parameter takes in the index of the first value. The recommended way to use this struct is with an enum. See core::scoring::hbonds::graph::AtomInfo for an example.
template<unsigned int NUM_ELEMS, unsigned int BASE_INDEX>
template<unsigned int const element>
template<unsigned int NUM_ELEMS, unsigned int BASE_INDEX>
template<unsigned int const element>