template<class NODE_TYPE>inline LCVMdoubly_linked_list_iterator<NODE_TYPE> & LCVMdoubly_linked_list_iterator<NODE_TYPE> to_head()

move the iterator to the front of the list

[more]classLCVMdoubly_linked_list NODE_TYPE friend ostream& operator<<<> (ostream&, const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)
[more]friend ostream& operator<< (ostream&, const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)
[more] LCVMdoubly_linked_list_iterator(LCVMdoubly_linked_list<NODE_TYPE>&)
constructor(needs a LCVMdoubly_linked_list)
[more] LCVMdoubly_linked_list_iterator(const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)
copy constructor
[more] ~LCVMdoubly_linked_list_iterator()
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & operator= (const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)
assignment operator
[more]int operator==(const LCVMdoubly_linked_list_iterator<NODE_TYPE>&) const
equality operator
[more]int operator!=(const LCVMdoubly_linked_list_iterator<NODE_TYPE>&) const
not equal operator
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & operator++()
advance the iterator
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & operator--()
backup the iterator
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & goto_element(const int)
n can be negative to start from the end of the list
[more]NODE_TYPE& operator[](const int)
this returns a reference to the data in the given node
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & next()
same as operator++()
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & prev()
same as operator--()
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & to_head()
moves the iterator to the head of the list
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & to_rear()
moves the iterator to the rear of the list
[more]int at_head() const
[more]int at_rear() const
check if the iterator is at the first node
[more]int is_null() const
check if the iterator is at the last node
[more]int not_null() const
check if the iterator is null
[more]NODE_TYPE get_data() const
check if the iterator is not null
[more]NODE_TYPE& operator*() const
return the data in the node
[more]NODE_TYPE& get_data_ref() const
return reference to data: same as operator*()
[more]LCVMdoubly_linked_list_iterator<NODE_TYPE> & set_data(const NODE_TYPE&)
set the data in the node: set up to allow chaining
[more]int get_size() const
[more]int is_empty() const
return a count of the nodes in a list
[more]int not_empty() const
check if the list is empty
[more]void print(ostream&) const
check if the list is not empty
oLCVMdoubly_linked_list<NODE_TYPE> * list
oLCVMdoubly_linked_list_node_base* node
the list we are iterating
o
the current node


Documentation

move the iterator to the front of the list
oclassLCVMdoubly_linked_list NODE_TYPE friend ostream& operator<<<> (ostream&, const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)

ofriend ostream& operator<< (ostream&, const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)

o LCVMdoubly_linked_list_iterator(LCVMdoubly_linked_list<NODE_TYPE>&)
constructor(needs a LCVMdoubly_linked_list)

o LCVMdoubly_linked_list_iterator(const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)
copy constructor

o ~LCVMdoubly_linked_list_iterator()

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & operator= (const LCVMdoubly_linked_list_iterator<NODE_TYPE>&)
assignment operator

oint operator==(const LCVMdoubly_linked_list_iterator<NODE_TYPE>&) const
equality operator

oint operator!=(const LCVMdoubly_linked_list_iterator<NODE_TYPE>&) const
not equal operator

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & operator++()
advance the iterator

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & operator--()
backup the iterator

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & goto_element(const int)
n can be negative to start from the end of the list

oNODE_TYPE& operator[](const int)
this returns a reference to the data in the given node

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & next()
same as operator++()

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & prev()
same as operator--()

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & to_head()
moves the iterator to the head of the list

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & to_rear()
moves the iterator to the rear of the list

oint at_head() const

oint at_rear() const
check if the iterator is at the first node

oint is_null() const
check if the iterator is at the last node

oint not_null() const
check if the iterator is null

oNODE_TYPE get_data() const
check if the iterator is not null

oNODE_TYPE& operator*() const
return the data in the node

oNODE_TYPE& get_data_ref() const
return reference to data: same as operator*()

oLCVMdoubly_linked_list_iterator<NODE_TYPE> & set_data(const NODE_TYPE&)
set the data in the node: set up to allow chaining

oint get_size() const

oint is_empty() const
return a count of the nodes in a list

oint not_empty() const
check if the list is empty

ovoid print(ostream&) const
check if the list is not empty

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.