SDSL 3.0.3
Succinct Data Structure Library
|
A forward iterator for a breath first traversal of a tree. More...
#include <cst_iterators.hpp>
Public Types | |
using | iterator_category = std::forward_iterator_tag |
using | value_type = typename Cst::node_type |
using | difference_type = std::ptrdiff_t |
using | pointer = value_type * |
using | reference = value_type & |
typedef const value_type | const_reference |
typedef Cst::size_type | size_type |
typedef cst_bfs_iterator< Cst, Queue > | iterator |
typedef Queue | queue_type |
Public Member Functions | |
cst_bfs_iterator (Cst const *cst, const value_type node, bool valid=true, bool end_it=false) | |
Constructor. | |
size_type | size () const |
Returns the current number of nodes in the queue. | |
const_reference | operator* () const |
Method for dereferencing the iterator. | |
iterator & | operator++ () |
Prefix increment of the iterator. | |
iterator | operator++ (int) |
Postfix increment of the iterator. | |
bool | operator== (iterator const &it) const |
Equality operator. | |
bool | operator!= (iterator const &it) const |
Inequality operator. |
A forward iterator for a breath first traversal of a tree.
Cst | A class which fulfills the CST concept |
Queue | A queue for the traversal. Note that for large data, you should use an external implementation of a queue. |
Definition at line 299 of file cst_iterators.hpp.
typedef const value_type sdsl::cst_bfs_iterator< Cst, Queue >::const_reference |
Definition at line 308 of file cst_iterators.hpp.
using sdsl::cst_bfs_iterator< Cst, Queue >::difference_type = std::ptrdiff_t |
Definition at line 304 of file cst_iterators.hpp.
typedef cst_bfs_iterator<Cst, Queue> sdsl::cst_bfs_iterator< Cst, Queue >::iterator |
Definition at line 310 of file cst_iterators.hpp.
using sdsl::cst_bfs_iterator< Cst, Queue >::iterator_category = std::forward_iterator_tag |
Definition at line 302 of file cst_iterators.hpp.
using sdsl::cst_bfs_iterator< Cst, Queue >::pointer = value_type * |
Definition at line 305 of file cst_iterators.hpp.
typedef Queue sdsl::cst_bfs_iterator< Cst, Queue >::queue_type |
Definition at line 311 of file cst_iterators.hpp.
using sdsl::cst_bfs_iterator< Cst, Queue >::reference = value_type & |
Definition at line 306 of file cst_iterators.hpp.
typedef Cst::size_type sdsl::cst_bfs_iterator< Cst, Queue >::size_type |
Definition at line 309 of file cst_iterators.hpp.
using sdsl::cst_bfs_iterator< Cst, Queue >::value_type = typename Cst::node_type |
Definition at line 303 of file cst_iterators.hpp.
|
inline |
Constructor.
cst | Pointer to the compressed suffix tree. |
node | Root node of the traversal. |
valid | State of the iterator. |
end | If valid=true and end=true, we get the end() iterator otherwise `‘end’' has no effect. |
Definition at line 326 of file cst_iterators.hpp.
|
inline |
Inequality operator.
Definition at line 395 of file cst_iterators.hpp.
|
inline |
Method for dereferencing the iterator.
Definition at line 343 of file cst_iterators.hpp.
|
inline |
Prefix increment of the iterator.
Definition at line 349 of file cst_iterators.hpp.
|
inline |
Postfix increment of the iterator.
Definition at line 370 of file cst_iterators.hpp.
|
inline |
Equality operator.
Definition at line 378 of file cst_iterators.hpp.
|
inline |
Returns the current number of nodes in the queue.
Definition at line 337 of file cst_iterators.hpp.