47 namespace StrideIterPack {
57 template<
class T_iterator_type,
class T_value_type,
class T_reference_type
58 ,
class T_pointer_type,
class T_difference_type>
92 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
96 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
209 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
217 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
218 inline bool operator<(const stride_iter<Iter,Val,Ref,Ptr,Diff>& itr1,
221 return itr1.operator->() < itr2.operator->();
224 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
225 inline bool operator<=(const stride_iter<Iter,Val,Ref,Ptr,Diff>& itr1,
228 return itr1.operator->() <= itr2.operator->();
231 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
235 return itr1.operator->() > itr2.operator->();
238 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
242 return itr1.operator->() >= itr2.operator->();
245 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
249 return itr1.operator->() == itr2.operator->();
252 template<
class Iter,
class Val,
class Ref,
class Ptr,
class Diff>
256 return itr1.operator->() != itr2.operator->();
263 #endif // STRIDE_ITER_H
stride_iter & operator-=(difference_type n)
itr -= n
stride_iter(iterator_type current, difference_type stride)
constructs to the desired sliced iterator
std::random_access_iterator_tag iterator_category
iterator_type current() const
T_reference_type reference
stride_iter & operator--()
–itr
stride_iter(const stride_iter< Iter, Val, Ref, Ptr, Diff > &rhs)
convert type of iterators (mainly for non-const to const)
stride_iter & operator++()
++itr
bool operator!=(const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr1, const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr2)
itr1 != itr2
C++ Standard Library compatable iterator class for accesing nonunit stride arrays of data...
bool operator==(const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr1, const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr2)
itr1 == itr2
stride_iter operator-(difference_type n)
itr - n
const stride_iter operator--(int)
itr–
const stride_iter operator+(difference_type n) const
itr + n
reference operator*() const
difference_type stride() const
const stride_iter operator-(difference_type n) const
itr - n
stride_iter()
constructs to a null iterator
T_iterator_type iterator_type
const stride_iter< Iter, Val, Ref, Ptr, Diff > operator+(Diff n, const stride_iter< Iter, Val, Ref, Ptr, Diff > itr)
Allow difference_type as lhs argument in n + itr.
pointer operator->() const
const stride_iter operator++(int)
itr++
const f_dbl_prec const f_int const f_int const f_int f_dbl_prec rhs[]
stride_iter & operator=(const stride_iter< Iter, Val, Ref, Ptr, Diff > &rhs)
assign different types of iterators (mainly for non-const to const)
difference_type operator-(const stride_iter &itr) const
distance = itr1 - itr2 (distance between elements)
bool operator>(const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr1, const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr2)
itr1 > itr 2
bool operator>=(const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr1, const stride_iter< Iter, Val, Ref, Ptr, Diff > &itr2)
itr1 >= itr2
stride_iter operator+(difference_type n)
itr + n
stride_iter(iterator_type current)
constructs to the standard iterator (behaves as) (increment 1). Allows conversion from iterator...
stride_iter & operator+=(difference_type n)
itr += n
reference operator[](difference_type n) const
T_difference_type difference_type