claw 1.9.0
 
Loading...
Searching...
No Matches
claw::it_index< T > Class Template Reference

A class to manage an index and an iterator easily. More...

#include <it_index.hpp>

Public Types

typedef std::iterator_traits< T >::value_type value_type
 
typedef std::iterator_traits< T >::difference_type difference_type
 
typedef std::iterator_traits< T >::pointer pointer
 
typedef std::iterator_traits< T >::reference reference
 

Public Member Functions

 it_index ()
 Constructor.
 
 it_index (const T &it, int index=0)
 Constructor.
 
 it_index (const it_index< T > &that)
 Copy constructor.
 
void set (const T &it, int index)
 Change the current pair.
 
bool operator< (const it_index< T > &that) const
 
bool operator< (const T &it) const
 
bool operator< (int index) const
 
bool operator<= (const it_index< T > &that) const
 
bool operator<= (const T &it) const
 
bool operator<= (int index) const
 
bool operator> (const it_index< T > &that) const
 
bool operator> (const T &it) const
 
bool operator> (int index) const
 
bool operator>= (const it_index< T > &that) const
 
bool operator>= (const T &it) const
 
bool operator>= (int index) const
 
bool operator== (const it_index< T > &that) const
 
bool operator== (const T &it) const
 
bool operator== (int index) const
 
bool operator!= (const it_index< T > &that) const
 
bool operator!= (const T &it) const
 
bool operator!= (int index) const
 
it_index< T > operator+ (int index) const
 
it_index< T > operator- (int index) const
 
it_index< T > operator* (int index) const
 
it_index< T > operator/ (int index) const
 
reference operator* () const
 
pointer operator-> () const
 
it_index< T > & operator++ ()
 
it_index< T > operator++ (int)
 
it_index< T > & operator-- ()
 
it_index< T > operator-- (int)
 
it_index< T > & operator+= (int index)
 
it_index< T > & operator-= (int index)
 
it_index< T > & operator*= (int index)
 
it_index< T > & operator/= (int index)
 
 operator int () const
 
 operator T () const
 

Detailed Description

template<class T>
class claw::it_index< T >

A class to manage an index and an iterator easily.

Parameters
TType of the iterator.
Author
Julien Jorge

Definition at line 43 of file it_index.hpp.

Member Typedef Documentation

◆ difference_type

template<class T>
typedef std::iterator_traits<T>::difference_type claw::it_index< T >::difference_type

Definition at line 47 of file it_index.hpp.

◆ pointer

template<class T>
typedef std::iterator_traits<T>::pointer claw::it_index< T >::pointer

Definition at line 48 of file it_index.hpp.

◆ reference

template<class T>
typedef std::iterator_traits<T>::reference claw::it_index< T >::reference

Definition at line 49 of file it_index.hpp.

◆ value_type

template<class T>
typedef std::iterator_traits<T>::value_type claw::it_index< T >::value_type

Definition at line 46 of file it_index.hpp.

Constructor & Destructor Documentation

◆ it_index() [1/3]

template<class T>
claw::it_index< T >::it_index ( )
inline

Constructor.

Definition at line 60 of file it_index.hpp.

◆ it_index() [2/3]

template<class T>
claw::it_index< T >::it_index ( const T & it,
int index = 0 )
inline

Constructor.

Parameters
itThe iterator.
indexIterator's position.

Definition at line 70 of file it_index.hpp.

◆ it_index() [3/3]

template<class T>
claw::it_index< T >::it_index ( const it_index< T > & that)
inline

Copy constructor.

Parameters
thatit_index to copy from.

Definition at line 79 of file it_index.hpp.

Member Function Documentation

◆ operator int()

template<class T>
claw::it_index< T >::operator int ( ) const
inline

Definition at line 260 of file it_index.hpp.

◆ operator T()

template<class T>
claw::it_index< T >::operator T ( ) const
inline

Definition at line 264 of file it_index.hpp.

◆ operator!=() [1/3]

template<class T>
bool claw::it_index< T >::operator!= ( const it_index< T > & that) const
inline

Definition at line 161 of file it_index.hpp.

◆ operator!=() [2/3]

template<class T>
bool claw::it_index< T >::operator!= ( const T & it) const
inline

Definition at line 165 of file it_index.hpp.

◆ operator!=() [3/3]

template<class T>
bool claw::it_index< T >::operator!= ( int index) const
inline

Definition at line 169 of file it_index.hpp.

◆ operator*() [1/2]

template<class T>
reference claw::it_index< T >::operator* ( ) const
inline

Definition at line 191 of file it_index.hpp.

◆ operator*() [2/2]

template<class T>
it_index< T > claw::it_index< T >::operator* ( int index) const
inline

Definition at line 182 of file it_index.hpp.

◆ operator*=()

template<class T>
it_index< T > & claw::it_index< T >::operator*= ( int index)
inline

Definition at line 246 of file it_index.hpp.

◆ operator+()

template<class T>
it_index< T > claw::it_index< T >::operator+ ( int index) const
inline

Definition at line 174 of file it_index.hpp.

◆ operator++() [1/2]

template<class T>
it_index< T > & claw::it_index< T >::operator++ ( )
inline

Definition at line 201 of file it_index.hpp.

◆ operator++() [2/2]

template<class T>
it_index< T > claw::it_index< T >::operator++ ( int )
inline

Definition at line 209 of file it_index.hpp.

◆ operator+=()

template<class T>
it_index< T > & claw::it_index< T >::operator+= ( int index)
inline

Definition at line 232 of file it_index.hpp.

◆ operator-()

template<class T>
it_index< T > claw::it_index< T >::operator- ( int index) const
inline

Definition at line 178 of file it_index.hpp.

◆ operator--() [1/2]

template<class T>
it_index< T > & claw::it_index< T >::operator-- ( )
inline

Definition at line 217 of file it_index.hpp.

◆ operator--() [2/2]

template<class T>
it_index< T > claw::it_index< T >::operator-- ( int )
inline

Definition at line 225 of file it_index.hpp.

◆ operator-=()

template<class T>
it_index< T > & claw::it_index< T >::operator-= ( int index)
inline

Definition at line 239 of file it_index.hpp.

◆ operator->()

template<class T>
pointer claw::it_index< T >::operator-> ( ) const
inline

Definition at line 195 of file it_index.hpp.

◆ operator/()

template<class T>
it_index< T > claw::it_index< T >::operator/ ( int index) const
inline

Definition at line 186 of file it_index.hpp.

◆ operator/=()

template<class T>
it_index< T > & claw::it_index< T >::operator/= ( int index)
inline

Definition at line 253 of file it_index.hpp.

◆ operator<() [1/3]

template<class T>
bool claw::it_index< T >::operator< ( const it_index< T > & that) const
inline

Definition at line 95 of file it_index.hpp.

◆ operator<() [2/3]

template<class T>
bool claw::it_index< T >::operator< ( const T & it) const
inline

Definition at line 100 of file it_index.hpp.

◆ operator<() [3/3]

template<class T>
bool claw::it_index< T >::operator< ( int index) const
inline

Definition at line 104 of file it_index.hpp.

◆ operator<=() [1/3]

template<class T>
bool claw::it_index< T >::operator<= ( const it_index< T > & that) const
inline

Definition at line 109 of file it_index.hpp.

◆ operator<=() [2/3]

template<class T>
bool claw::it_index< T >::operator<= ( const T & it) const
inline

Definition at line 113 of file it_index.hpp.

◆ operator<=() [3/3]

template<class T>
bool claw::it_index< T >::operator<= ( int index) const
inline

Definition at line 117 of file it_index.hpp.

◆ operator==() [1/3]

template<class T>
bool claw::it_index< T >::operator== ( const it_index< T > & that) const
inline

Definition at line 148 of file it_index.hpp.

◆ operator==() [2/3]

template<class T>
bool claw::it_index< T >::operator== ( const T & it) const
inline

Definition at line 152 of file it_index.hpp.

◆ operator==() [3/3]

template<class T>
bool claw::it_index< T >::operator== ( int index) const
inline

Definition at line 156 of file it_index.hpp.

◆ operator>() [1/3]

template<class T>
bool claw::it_index< T >::operator> ( const it_index< T > & that) const
inline

Definition at line 122 of file it_index.hpp.

◆ operator>() [2/3]

template<class T>
bool claw::it_index< T >::operator> ( const T & it) const
inline

Definition at line 126 of file it_index.hpp.

◆ operator>() [3/3]

template<class T>
bool claw::it_index< T >::operator> ( int index) const
inline

Definition at line 130 of file it_index.hpp.

◆ operator>=() [1/3]

template<class T>
bool claw::it_index< T >::operator>= ( const it_index< T > & that) const
inline

Definition at line 135 of file it_index.hpp.

◆ operator>=() [2/3]

template<class T>
bool claw::it_index< T >::operator>= ( const T & it) const
inline

Definition at line 139 of file it_index.hpp.

◆ operator>=() [3/3]

template<class T>
bool claw::it_index< T >::operator>= ( int index) const
inline

Definition at line 143 of file it_index.hpp.

◆ set()

template<class T>
void claw::it_index< T >::set ( const T & it,
int index )
inline

Change the current pair.

Parameters
itThe new iterator.
indexNew iterator's position.

Definition at line 89 of file it_index.hpp.


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