![]() |
aGrUM
0.16.0
|
Iterator for conveniently stepping through Nodes and Attributes. More...
#include <ticpp.h>
Public Member Functions | |
T * | begin (const Node *parent) const |
For for loop comparisons. More... | |
T * | end () const |
For for loop comparisons. More... | |
Iterator (const std::string &value="") | |
Constructor. More... | |
Iterator (T *node, const std::string &value="") | |
Constructor. More... | |
Iterator (const Iterator &it) | |
Constructor. More... | |
T * | Get () const |
Gets internal pointer. More... | |
Iterator & | operator= (const Iterator &it) |
Sets internal pointer. More... | |
Iterator & | operator= (T *p) |
Sets internal pointer. More... | |
Iterator & | operator++ () |
Sets internal pointer to the Next Sibling, or Iterator::END, if there are no more siblings. More... | |
Iterator | operator++ (int) |
Sets internal pointer to the Next Sibling, or Iterator::END, if there are no more siblings. More... | |
Iterator & | operator-- () |
Sets internal pointer to the Previous Sibling, or Iterator::END, if there are no prior siblings. More... | |
Iterator | operator-- (int) |
Sets internal pointer to the Previous Sibling, or Iterator::END, if there are no prior siblings. More... | |
bool | operator!= (const T *p) const |
Compares internal pointer. More... | |
bool | operator!= (const Iterator &it) const |
Compares internal pointer. More... | |
bool | operator== (T *p) const |
Compares internal pointer*. More... | |
bool | operator== (const Iterator &it) const |
Compares internal pointer. More... | |
T * | operator-> () const |
So Iterator behaves like a STL iterator. More... | |
T & | operator* () const |
So Iterator behaves like a STL iterator. More... | |
Iterator for conveniently stepping through Nodes and Attributes.
TinyXML++ introduces iterators:
Iterators have the added advantage of filtering by type:
Finally, Iterators also work with Attributes
|
inline |
Constructor.
value | If not empty, this iterator will only visit nodes with matching value. // Only iterates through Element nodes with value "ElementValue" ticpp::Iterator< ticpp::Element > child( "ElementValue" ); |
Definition at line 1152 of file ticpp.h.
|
inline |
|
inline |
|
inline |
For for loop comparisons.
parent | The parent of the nodes to iterate. |
Definition at line 1127 of file ticpp.h.
References ticpp::Node::IterateFirst().
|
inline |
For for loop comparisons.
|
inline |
|
inline |
|
inline |
Compares internal pointer.
Definition at line 1233 of file ticpp.h.
References ticpp::Iterator< T >::m_p, and ticpp::Iterator< T >::operator!=().
Referenced by ticpp::Iterator< T >::operator!=().
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Sets internal pointer.
Definition at line 1173 of file ticpp.h.
References ticpp::Iterator< T >::m_p, and ticpp::Iterator< T >::m_value.
|
inline |
|
inline |
|
inline |
Compares internal pointer.
Definition at line 1249 of file ticpp.h.
References ticpp::Iterator< T >::m_p, and ticpp::Iterator< T >::operator==().
Referenced by ticpp::Iterator< T >::operator==().
|
private |
Internal Pointer.
Definition at line 1114 of file ticpp.h.
Referenced by ticpp::Iterator< T >::operator!=(), ticpp::Iterator< T >::operator=(), and ticpp::Iterator< T >::operator==().
|
private |
Value for NextSibling calls.
Definition at line 1115 of file ticpp.h.
Referenced by ticpp::Iterator< T >::operator=().