![]() |
aGrUM 2.3.2
a C++ library for (probabilistic) graphical models
|
The iterators for IdSets. More...
#include <agrum/BN/learning/scores_and_tests/idSet.h>
Public Types | |
| using | iterator_category = std::forward_iterator_tag |
| types for STL compliance | |
| using | value_type = NodeId |
| types for STL compliance | |
| using | reference = NodeId& |
| types for STL compliance | |
| using | const_reference = const NodeId& |
| types for STL compliance | |
| using | pointer = NodeId* |
| types for STL compliance | |
| using | const_pointer = const NodeId* |
| types for STL compliance | |
| using | difference_type = std::ptrdiff_t |
| types for STL compliance | |
Public Member Functions | |
Constructors / Destructors | |
| IdCondSetIterator () | |
| default constructor | |
| IdCondSetIterator (const IdCondSet &idset) | |
| Constructor for a begin. | |
| IdCondSetIterator (const IdCondSetIterator &from) | |
| Copy constructor. | |
| IdCondSetIterator (IdCondSetIterator &&from) | |
| move constructor | |
| virtual | ~IdCondSetIterator () |
| destructor | |
Operators | |
| IdCondSetIterator & | operator= (const IdCondSetIterator &from) |
| copy operator | |
| IdCondSetIterator & | operator= (IdCondSetIterator &&from) |
| move operator | |
| NodeId | operator* () const |
| Gives access to the content of the iterator. | |
| bool | operator!= (const IdCondSetIterator &from) const |
| Checks whether two iterators point toward different elements. | |
| bool | operator== (const IdCondSetIterator &from) const |
| Checks whether two iterators point toward the same elements. | |
| IdCondSetIterator & | operator++ () |
| Makes the iterator point to the next element in the IdCondSet. | |
| IdCondSetIterator & | operator+= (const std::size_t i) |
| Makes the iterator point to i elements further in the IdCondSet. | |
| IdCondSetIterator | operator+ (const std::size_t i) |
| Returns a new iterator pointing to i further elements in the IdCondSet. | |
Accessors / Modifiers | |
| std::size_t | pos () const |
| Returns the position of the iterator in the IdCondSet. | |
The iterators for IdSets.
Definition at line 75 of file idCondSet.h.
| using gum::learning::IdCondSetIterator::const_pointer = const NodeId* |
types for STL compliance
Definition at line 84 of file idCondSet.h.
| using gum::learning::IdCondSetIterator::const_reference = const NodeId& |
types for STL compliance
Definition at line 82 of file idCondSet.h.
| using gum::learning::IdCondSetIterator::difference_type = std::ptrdiff_t |
types for STL compliance
Definition at line 85 of file idCondSet.h.
| using gum::learning::IdCondSetIterator::iterator_category = std::forward_iterator_tag |
types for STL compliance
Definition at line 79 of file idCondSet.h.
types for STL compliance
Definition at line 83 of file idCondSet.h.
types for STL compliance
Definition at line 81 of file idCondSet.h.
types for STL compliance
Definition at line 80 of file idCondSet.h.
| gum::learning::IdCondSetIterator::IdCondSetIterator | ( | ) |
default constructor
Referenced by IdCondSetIterator(), IdCondSetIterator(), operator!=(), operator+(), operator++(), operator+=(), operator=(), operator=(), and operator==().
| gum::learning::IdCondSetIterator::IdCondSetIterator | ( | const IdCondSet & | idset | ) |
Constructor for a begin.
| idset | The IdCondSet to iterate over. |
| gum::learning::IdCondSetIterator::IdCondSetIterator | ( | const IdCondSetIterator & | from | ) |
| gum::learning::IdCondSetIterator::IdCondSetIterator | ( | IdCondSetIterator && | from | ) |
|
virtual |
destructor
| bool gum::learning::IdCondSetIterator::operator!= | ( | const IdCondSetIterator & | from | ) | const |
Checks whether two iterators point toward different elements.
References IdCondSetIterator().
| NodeId gum::learning::IdCondSetIterator::operator* | ( | ) | const |
Gives access to the content of the iterator.
| UndefinedIteratorValue | Raised if the iterator points to nothing. |
| IdCondSetIterator gum::learning::IdCondSetIterator::operator+ | ( | const std::size_t | i | ) |
Returns a new iterator pointing to i further elements in the IdCondSet.
| i | The number of steps to move the iterator. |
References IdCondSetIterator().
| IdCondSetIterator & gum::learning::IdCondSetIterator::operator++ | ( | ) |
Makes the iterator point to the next element in the IdCondSet.
The above loop is guaranteed to parse the whole IdCondSet as long as no element is added to or deleted from the IdCondSet while being in the loop.
References IdCondSetIterator().
| IdCondSetIterator & gum::learning::IdCondSetIterator::operator+= | ( | const std::size_t | i | ) |
Makes the iterator point to i elements further in the IdCondSet.
| i | The number of steps to move the iterator. |
References IdCondSetIterator().
| IdCondSetIterator & gum::learning::IdCondSetIterator::operator= | ( | const IdCondSetIterator & | from | ) |
| IdCondSetIterator & gum::learning::IdCondSetIterator::operator= | ( | IdCondSetIterator && | from | ) |
| bool gum::learning::IdCondSetIterator::operator== | ( | const IdCondSetIterator & | from | ) | const |
Checks whether two iterators point toward the same elements.
References IdCondSetIterator().
| std::size_t gum::learning::IdCondSetIterator::pos | ( | ) | const |
Returns the position of the iterator in the IdCondSet.
| UndefinedIteratorValue | Raised on end() |