internal iterator class More...
#include <xmlstorage.h>
Public Types | |
typedef const_iterator | myType |
Public Member Functions | |
const_iterator (XMLStreamReader &reader, bool is_end) | |
const XMLStreamReader & | operator-> () const |
XS_String | operator* () const |
myType & | operator++ () |
myType | operator++ (int) |
bool | operator== (const myType &other) const |
bool | operator!= (const myType &other) const |
Protected Member Functions | |
void | search_next () |
Protected Attributes | |
XMLStreamReader & | _reader |
int | _start_level |
bool | _is_end |
bool | _at_end |
internal iterator class
Definition at line 3301 of file xmlstorage.h.
Definition at line 3303 of file xmlstorage.h.
XMLStorage::XMLStreamChildrenIterator::const_iterator::const_iterator | ( | XMLStreamReader & | reader, |
bool | is_end | ||
) | [inline] |
Definition at line 3305 of file xmlstorage.h.
References search_next().
: _reader(reader), _start_level(reader._level), _is_end(is_end) { search_next(); }
bool XMLStorage::XMLStreamChildrenIterator::const_iterator::operator!= | ( | const myType & | other ) | const [inline] |
Definition at line 3351 of file xmlstorage.h.
References _at_end, _is_end, _reader, and XMLStorage::XMLStreamReader::str().
{ if (other._is_end) return !_at_end; else if (_is_end) return !other._at_end; else return _reader.str() != other._reader.str(); }
XS_String XMLStorage::XMLStreamChildrenIterator::const_iterator::operator* | ( | ) | const [inline] |
Definition at line 3318 of file xmlstorage.h.
References _reader, and XMLStorage::XMLStreamReader::str().
{ return _reader.str(); }
myType XMLStorage::XMLStreamChildrenIterator::const_iterator::operator++ | ( | int | ) | [inline] |
Definition at line 3331 of file xmlstorage.h.
References _at_end, and search_next().
{ myType ret = *this; if (!_at_end) search_next(); return ret; }
myType& XMLStorage::XMLStreamChildrenIterator::const_iterator::operator++ | ( | ) | [inline] |
Definition at line 3323 of file xmlstorage.h.
References _at_end, and search_next().
{ if (!_at_end) search_next(); return *this; }
const XMLStreamReader& XMLStorage::XMLStreamChildrenIterator::const_iterator::operator-> | ( | ) | const [inline] |
bool XMLStorage::XMLStreamChildrenIterator::const_iterator::operator== | ( | const myType & | other ) | const [inline] |
Definition at line 3341 of file xmlstorage.h.
References _at_end, _is_end, _reader, and XMLStorage::XMLStreamReader::str().
{ if (other._is_end) return _at_end; else if (_is_end) return other._at_end; else return _reader.str() == other._reader.str(); }
void XMLStorage::XMLStreamChildrenIterator::const_iterator::search_next | ( | ) | [inline, protected] |
Definition at line 3367 of file xmlstorage.h.
References _at_end, XMLStorage::XMLStreamReader::_level, _reader, _start_level, and XMLStorage::XMLStreamReader::next().
Referenced by const_iterator(), and operator++().
{ while(!_at_end) { _reader.next(); if (_reader._level == _start_level) _at_end = true; } }
bool XMLStorage::XMLStreamChildrenIterator::const_iterator::_at_end [protected] |
Definition at line 3365 of file xmlstorage.h.
Referenced by operator!=(), operator++(), operator==(), and search_next().
bool XMLStorage::XMLStreamChildrenIterator::const_iterator::_is_end [protected] |
Definition at line 3364 of file xmlstorage.h.
Referenced by operator!=(), and operator==().
Definition at line 3362 of file xmlstorage.h.
Referenced by operator!=(), operator*(), operator->(), operator==(), and search_next().
Definition at line 3363 of file xmlstorage.h.
Referenced by search_next().