RobWorkProject  24.5.15-
Public Types | Public Member Functions | List of all members
ConstVectorIterator< T > Class Template Reference

Forward iterator for vectors of pointers to const T. More...

#include <VectorIterator.hpp>

Public Types

typedef I::iterator_category iterator_category
 
typedef T const value_type
 
typedef T const * pointer
 
typedef T const & reference
 
typedef I::difference_type difference_type
 

Public Member Functions

 ConstVectorIterator (I pos)
 Iterator for the element at pos.
 
const T & operator* () const
 Reference to the T element.
 
const T * operator-> () const
 Pointer to the T element.
 
ConstVectorIteratoroperator++ ()
 Increments the position of the iterator. More...
 
ConstVectorIterator operator++ (int)
 Increments the position of the iterator. More...
 
bool operator== (const ConstVectorIterator &other) const
 Tests whether the positions of two iterators are equal. More...
 
bool operator!= (const ConstVectorIterator &other) const
 Tests whether the positions of two iterators are unequal. More...
 
 ConstVectorIterator (VectorIterator< T > pos)
 Implicit conversion from iterators.
 

Detailed Description

template<typename T>
class rw::common::ConstVectorIterator< T >

Forward iterator for vectors of pointers to const T.

Member Typedef Documentation

◆ difference_type

typedef I::difference_type difference_type

Difference type.

◆ iterator_category

typedef I::iterator_category iterator_category

Iterator category.

◆ pointer

typedef T const* pointer

Pointer type.

◆ reference

typedef T const& reference

Reference type.

◆ value_type

typedef T const value_type

Value type.

Member Function Documentation

◆ operator!=()

bool operator!= ( const ConstVectorIterator< T > &  other) const
inline

Tests whether the positions of two iterators are unequal.

Parameters
other[in] VectorIterator to compare with
Returns
true if unequal

◆ operator++() [1/2]

ConstVectorIterator& operator++ ( )
inline

Increments the position of the iterator.

Returns
Reference to the incremented iterator

◆ operator++() [2/2]

ConstVectorIterator operator++ ( int  )
inline

Increments the position of the iterator.

Returns
the VectorIterator with the value before the incrementation

◆ operator==()

bool operator== ( const ConstVectorIterator< T > &  other) const
inline

Tests whether the positions of two iterators are equal.

Parameters
other[in] VectorIterator to compare with
Returns
true if equal

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