Vowpal Wabbit
Public Types | Public Member Functions | Private Attributes | List of all members
vw_slim::internal::collection_pair_iterator< It1, It2 > Class Template Reference

#include <vw_slim_predict.h>

Inheritance diagram for vw_slim::internal::collection_pair_iterator< It1, It2 >:

Public Types

using Iter = collection_pair_iterator< It1, It2 >
 
using Loc = location_value< It1, It2 >
 
using Ref = location_reference< It1, It2 >
 

Public Member Functions

 collection_pair_iterator (It1 first, It2 second)
 
 collection_pair_iterator ()=default
 
 collection_pair_iterator (const collection_pair_iterator &rhs)=default
 
collection_pair_iteratoroperator= (const collection_pair_iterator &rhs)=default
 
bool operator== (const Iter &rhs) const
 
bool operator!= (const Iter &rhs) const
 
Ref operator* ()
 
Iteroperator++ ()
 
Iter operator++ (int)
 
Iteroperator-- ()
 
Iter operator-- (int)
 
Iter operator+ (const size_t n) const
 
Iter operator- (const size_t n) const
 
size_t operator- (const Iter &rhs) const
 
bool operator< (const Iter &rhs) const
 
bool operator> (const Iter &rhs) const
 
bool operator<= (const Iter &rhs) const
 
bool operator>= (const Iter &rhs) const
 
Iteroperator+= (size_t n)
 
Iteroperator-= (size_t n)
 

Private Attributes

It1 _ptr1
 
It2 _ptr2
 

Detailed Description

template<typename It1, typename It2>
class vw_slim::internal::collection_pair_iterator< It1, It2 >

Definition at line 74 of file vw_slim_predict.h.

Member Typedef Documentation

◆ Iter

template<typename It1 , typename It2 >
using vw_slim::internal::collection_pair_iterator< It1, It2 >::Iter = collection_pair_iterator<It1, It2>

Definition at line 84 of file vw_slim_predict.h.

◆ Loc

template<typename It1 , typename It2 >
using vw_slim::internal::collection_pair_iterator< It1, It2 >::Loc = location_value<It1, It2>

Definition at line 85 of file vw_slim_predict.h.

◆ Ref

template<typename It1 , typename It2 >
using vw_slim::internal::collection_pair_iterator< It1, It2 >::Ref = location_reference<It1, It2>

Definition at line 86 of file vw_slim_predict.h.

Constructor & Destructor Documentation

◆ collection_pair_iterator() [1/3]

template<typename It1 , typename It2 >
vw_slim::internal::collection_pair_iterator< It1, It2 >::collection_pair_iterator ( It1  first,
It2  second 
)
inline

◆ collection_pair_iterator() [2/3]

template<typename It1 , typename It2 >
vw_slim::internal::collection_pair_iterator< It1, It2 >::collection_pair_iterator ( )
default

◆ collection_pair_iterator() [3/3]

template<typename It1 , typename It2 >
vw_slim::internal::collection_pair_iterator< It1, It2 >::collection_pair_iterator ( const collection_pair_iterator< It1, It2 > &  rhs)
default

Member Function Documentation

◆ operator!=()

template<typename It1 , typename It2 >
bool vw_slim::internal::collection_pair_iterator< It1, It2 >::operator!= ( const Iter rhs) const
inline

Definition at line 97 of file vw_slim_predict.h.

References VW::config::operator==().

97 { return !(operator==(rhs)); }
bool operator==(const Iter &rhs) const

◆ operator*()

template<typename It1 , typename It2 >
Ref vw_slim::internal::collection_pair_iterator< It1, It2 >::operator* ( )
inline

Definition at line 101 of file vw_slim_predict.h.

101 { return Ref(_ptr1, _ptr2); } // Non-conforming - normally returns loc&
location_reference< It1, It2 > Ref

◆ operator+()

template<typename It1 , typename It2 >
Iter vw_slim::internal::collection_pair_iterator< It1, It2 >::operator+ ( const size_t  n) const
inline

◆ operator++() [1/2]

template<typename It1 , typename It2 >
Iter& vw_slim::internal::collection_pair_iterator< It1, It2 >::operator++ ( )
inline

Definition at line 104 of file vw_slim_predict.h.

105  {
106  ++_ptr1;
107  ++_ptr2;
108  return *this;
109  }

◆ operator++() [2/2]

template<typename It1 , typename It2 >
Iter vw_slim::internal::collection_pair_iterator< It1, It2 >::operator++ ( int  )
inline

Definition at line 111 of file vw_slim_predict.h.

112  {
113  Iter ret(*this);
114  ++_ptr1;
115  ++_ptr2;
116  return ret;
117  }
collection_pair_iterator< It1, It2 > Iter

◆ operator+=()

template<typename It1 , typename It2 >
Iter& vw_slim::internal::collection_pair_iterator< It1, It2 >::operator+= ( size_t  n)
inline

Definition at line 148 of file vw_slim_predict.h.

149  {
150  _ptr1 += n;
151  _ptr2 += n;
152  return *this;
153  }

◆ operator-() [1/2]

template<typename It1 , typename It2 >
Iter vw_slim::internal::collection_pair_iterator< It1, It2 >::operator- ( const size_t  n) const
inline

◆ operator-() [2/2]

template<typename It1 , typename It2 >
size_t vw_slim::internal::collection_pair_iterator< It1, It2 >::operator- ( const Iter rhs) const
inline

◆ operator--() [1/2]

template<typename It1 , typename It2 >
Iter& vw_slim::internal::collection_pair_iterator< It1, It2 >::operator-- ( )
inline

Definition at line 120 of file vw_slim_predict.h.

121  {
122  --_ptr1;
123  --_ptr2;
124  return *this;
125  }

◆ operator--() [2/2]

template<typename It1 , typename It2 >
Iter vw_slim::internal::collection_pair_iterator< It1, It2 >::operator-- ( int  )
inline

Definition at line 127 of file vw_slim_predict.h.

128  {
129  Iter ret(*this);
130  --_ptr1;
131  --_ptr2;
132  return ret;
133  }
collection_pair_iterator< It1, It2 > Iter

◆ operator-=()

template<typename It1 , typename It2 >
Iter& vw_slim::internal::collection_pair_iterator< It1, It2 >::operator-= ( size_t  n)
inline

Definition at line 155 of file vw_slim_predict.h.

156  {
157  _ptr1 -= n;
158  _ptr2 -= n;
159  return *this;
160  }

◆ operator<()

template<typename It1 , typename It2 >
bool vw_slim::internal::collection_pair_iterator< It1, It2 >::operator< ( const Iter rhs) const
inline

◆ operator<=()

template<typename It1 , typename It2 >
bool vw_slim::internal::collection_pair_iterator< It1, It2 >::operator<= ( const Iter rhs) const
inline

◆ operator=()

template<typename It1 , typename It2 >
collection_pair_iterator& vw_slim::internal::collection_pair_iterator< It1, It2 >::operator= ( const collection_pair_iterator< It1, It2 > &  rhs)
default

◆ operator==()

template<typename It1 , typename It2 >
bool vw_slim::internal::collection_pair_iterator< It1, It2 >::operator== ( const Iter rhs) const
inline

◆ operator>()

template<typename It1 , typename It2 >
bool vw_slim::internal::collection_pair_iterator< It1, It2 >::operator> ( const Iter rhs) const
inline

◆ operator>=()

template<typename It1 , typename It2 >
bool vw_slim::internal::collection_pair_iterator< It1, It2 >::operator>= ( const Iter rhs) const
inline

Member Data Documentation

◆ _ptr1

template<typename It1 , typename It2 >
It1 vw_slim::internal::collection_pair_iterator< It1, It2 >::_ptr1
private

◆ _ptr2

template<typename It1 , typename It2 >
It2 vw_slim::internal::collection_pair_iterator< It1, It2 >::_ptr2
private

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