Public Types | Public Member Functions | Protected Member Functions | Protected Attributes

XMLStorage::XMLStreamChildrenFilter::const_iterator Struct Reference

internal iterator class More...

#include <xmlstorage.h>

Collaboration diagram for XMLStorage::XMLStreamChildrenFilter::const_iterator:
Collaboration graph
[legend]

List of all members.

Public Types

typedef const_iterator myType

Public Member Functions

 const_iterator (XMLStreamReader &reader, const XS_String &filter_name, bool is_end)
const XMLStreamReaderoperator-> () const
XS_String operator* () const
myTypeoperator++ ()
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
XS_String _filter_name
int _start_level
bool _is_end
bool _at_end

Detailed Description

internal iterator class

Definition at line 3319 of file xmlstorage.h.


Member Typedef Documentation

Definition at line 3321 of file xmlstorage.h.


Constructor & Destructor Documentation

XMLStorage::XMLStreamChildrenFilter::const_iterator::const_iterator ( XMLStreamReader reader,
const XS_String filter_name,
bool  is_end 
) [inline]

Definition at line 3323 of file xmlstorage.h.

References search_next().

         :  _reader(reader),
            _filter_name(filter_name),
            _start_level(reader._level),
            _is_end(is_end)
        {
            search_next();
        }

Here is the call graph for this function:


Member Function Documentation

bool XMLStorage::XMLStreamChildrenFilter::const_iterator::operator!= ( const myType other ) const [inline]

Definition at line 3370 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();
        }

Here is the call graph for this function:

XS_String XMLStorage::XMLStreamChildrenFilter::const_iterator::operator* (  ) const [inline]

Definition at line 3337 of file xmlstorage.h.

References _reader, and XMLStorage::XMLStreamReader::str().

        {
            return _reader.str();
        }

Here is the call graph for this function:

myType XMLStorage::XMLStreamChildrenFilter::const_iterator::operator++ ( int   ) [inline]

Definition at line 3350 of file xmlstorage.h.

References _at_end, and search_next().

        {
            myType ret = *this;

            if (!_at_end)
                search_next();

            return ret;
        }

Here is the call graph for this function:

myType& XMLStorage::XMLStreamChildrenFilter::const_iterator::operator++ (  ) [inline]

Definition at line 3342 of file xmlstorage.h.

References _at_end, and search_next().

        {
            if (!_at_end)
                search_next();

            return *this;
        }

Here is the call graph for this function:

const XMLStreamReader& XMLStorage::XMLStreamChildrenFilter::const_iterator::operator-> (  ) const [inline]

Definition at line 3332 of file xmlstorage.h.

References _reader.

        {
            return _reader;
        }
bool XMLStorage::XMLStreamChildrenFilter::const_iterator::operator== ( const myType other ) const [inline]

Definition at line 3360 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();
        }

Here is the call graph for this function:

void XMLStorage::XMLStreamChildrenFilter::const_iterator::search_next (  ) [inline, protected]

Definition at line 3387 of file xmlstorage.h.

References _at_end, _filter_name, XMLStorage::XMLStreamReader::_level, _reader, _start_level, and XMLStorage::XMLStreamReader::next_skip_others().

Referenced by const_iterator(), and operator++().

        {
            while(!_at_end) {
                _reader.next_skip_others(_filter_name);

                if (_reader._level == _start_level)
                    _at_end = true;
            }
        }

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Definition at line 3385 of file xmlstorage.h.

Referenced by operator!=(), operator++(), operator==(), and search_next().

Definition at line 3382 of file xmlstorage.h.

Referenced by search_next().

Definition at line 3384 of file xmlstorage.h.

Referenced by operator!=(), and operator==().

Definition at line 3381 of file xmlstorage.h.

Referenced by operator!=(), operator*(), operator->(), operator==(), and search_next().

Definition at line 3383 of file xmlstorage.h.

Referenced by search_next().


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

ROS Explorer Source Code Documentation
generated on 02.01.2013 by doxygen

ROS Explorer Homepage