tree  release 2.0
Public Member Functions | Private Attributes | List of all members
tree< T, tree_node_allocator >::breadth_first_queued_iterator Class Reference

Breadth-first iterator, using a queue. More...

#include <tree.hh>

Inheritance diagram for tree< T, tree_node_allocator >::breadth_first_queued_iterator:
tree< T, tree_node_allocator >::iterator_base

Public Member Functions

 breadth_first_queued_iterator ()
 
 breadth_first_queued_iterator (tree_node *)
 
 breadth_first_queued_iterator (const iterator_base &)
 
bool operator== (const breadth_first_queued_iterator &) const
 
bool operator!= (const breadth_first_queued_iterator &) const
 
breadth_first_queued_iteratoroperator++ ()
 
breadth_first_queued_iterator operator++ (int)
 
breadth_first_queued_iteratoroperator+= (unsigned int)
 
- Public Member Functions inherited from tree< T, tree_node_allocator >::iterator_base
 iterator_base ()
 
 iterator_base (tree_node *)
 
T & operator* () const
 
T * operator-> () const
 
void skip_children ()
 When called, the next increment/decrement skips children of this node. More...
 
void skip_children (bool skip)
 
unsigned int number_of_children () const
 Number of children of the node pointed to by the iterator. More...
 
sibling_iterator begin () const
 
sibling_iterator end () const
 

Private Attributes

std::queue< tree_node * > traversal_queue
 

Additional Inherited Members

- Public Types inherited from tree< T, tree_node_allocator >::iterator_base
typedef T value_type
 
typedef T * pointer
 
typedef T & reference
 
typedef size_t size_type
 
typedef ptrdiff_t difference_type
 
typedef std::bidirectional_iterator_tag iterator_category
 
- Public Attributes inherited from tree< T, tree_node_allocator >::iterator_base
tree_nodenode
 
- Protected Attributes inherited from tree< T, tree_node_allocator >::iterator_base
bool skip_current_children_
 

Detailed Description

template<class T, class tree_node_allocator = std::allocator<tree_node_<T> >>
class tree< T, tree_node_allocator >::breadth_first_queued_iterator

Breadth-first iterator, using a queue.

Constructor & Destructor Documentation

template<class T , class tree_node_allocator >
tree< T, tree_node_allocator >::breadth_first_queued_iterator::breadth_first_queued_iterator ( )
template<class T , class tree_node_allocator >
tree< T, tree_node_allocator >::breadth_first_queued_iterator::breadth_first_queued_iterator ( tree_node tn)
template<class T , class tree_node_allocator >
tree< T, tree_node_allocator >::breadth_first_queued_iterator::breadth_first_queued_iterator ( const iterator_base other)

Member Function Documentation

template<class T , class tree_node_allocator >
bool tree< T, tree_node_allocator >::breadth_first_queued_iterator::operator!= ( const breadth_first_queued_iterator other) const
template<class T , class tree_node_allocator >
tree< T, tree_node_allocator >::breadth_first_queued_iterator & tree< T, tree_node_allocator >::breadth_first_queued_iterator::operator++ ( )
template<class T , class tree_node_allocator >
tree< T, tree_node_allocator >::breadth_first_queued_iterator tree< T, tree_node_allocator >::breadth_first_queued_iterator::operator++ ( int  )
template<class T , class tree_node_allocator >
tree< T, tree_node_allocator >::breadth_first_queued_iterator & tree< T, tree_node_allocator >::breadth_first_queued_iterator::operator+= ( unsigned int  num)
template<class T , class tree_node_allocator >
bool tree< T, tree_node_allocator >::breadth_first_queued_iterator::operator== ( const breadth_first_queued_iterator other) const

Member Data Documentation

template<class T, class tree_node_allocator = std::allocator<tree_node_<T> >>
std::queue<tree_node *> tree< T, tree_node_allocator >::breadth_first_queued_iterator::traversal_queue
private

The documentation for this class was generated from the following file: