Range-v3
Range algorithms, views, and actions for the Standard Library
ranges::v3::basic_iterator< Cur > Struct Template Reference
+ Inheritance diagram for ranges::v3::basic_iterator< Cur >:

Friends

template<typename Cur2 >
struct basic_iterator
 
template<typename C = Cur, requires = (Same<C, Cur>() && detail::InputCursor<Cur>())>
auto iter_move (basic_iterator const &it) noexcept(noexcept(decltype(range_access::move(static_cast< basic_iterator< C > const &>(it).pos()))(range_access::move(static_cast< basic_iterator< C > const &>(it).pos())))) -> decltype(range_access::move(static_cast< basic_iterator< C > const &>(it).pos()))
 
template<class Cur2 , requires = (detail::CursorSentinel<Cur2, Cur>())>
constexpr bool operator!= (basic_iterator const &left, basic_iterator< Cur2 > const &right)
 
template<class S , requires = (detail::CursorSentinel<S, Cur>())>
constexpr bool operator!= (basic_iterator const &left, S const &right)
 
template<class S , requires = (detail::CursorSentinel<S, Cur>())>
constexpr bool operator!= (S const &left, basic_iterator const &right)
 
basic_iterator operator+ (basic_iterator left, difference_type n)
 
basic_iterator operator+ (difference_type n, basic_iterator right)
 
basic_iterator operator- (basic_iterator left, difference_type n)
 
template<typename Cur2 , requires = (detail::SizedCursorSentinel<Cur2, Cur>())>
difference_type operator- (basic_iterator< Cur2 > const &left, basic_iterator const &right)
 
template<typename S , requires = (detail::SizedCursorSentinel<S, Cur>())>
difference_type operator- (S const &left, basic_iterator const &right)
 
template<typename S , requires = (detail::SizedCursorSentinel<S, Cur>())>
difference_type operator- (basic_iterator const &left, S const &right)
 
bool operator< (basic_iterator const &left, basic_iterator const &right)
 
bool operator<= (basic_iterator const &left, basic_iterator const &right)
 
template<class Cur2 , requires = (detail::CursorSentinel<Cur2, Cur>())>
constexpr bool operator== (basic_iterator const &left, basic_iterator< Cur2 > const &right)
 
template<class S , requires = (detail::CursorSentinel<S, Cur>())>
constexpr bool operator== (basic_iterator const &left, S const &right)
 
template<class S , requires = (detail::CursorSentinel<S, Cur>())>
constexpr bool operator== (S const &left, basic_iterator const &right)
 
bool operator> (basic_iterator const &left, basic_iterator const &right)
 
bool operator>= (basic_iterator const &left, basic_iterator const &right)
 
struct ranges::range_access
 

Public Member Functions

 basic_iterator (Cur pos)
 
template<typename OtherCur , requires = (ConvertibleTo<OtherCur, Cur>() && Constructible<mixin_t, OtherCur>())>
 basic_iterator (basic_iterator< OtherCur > that)
 
constexpr const_reference_t operator* () const noexcept(noexcept(range_access::read(std::declval< Cur const &>())))
 
reference_t operator* () noexcept(noexcept(reference_t{std::declval< Cur &>()}))
 
constexpr const_reference_t operator* () const noexcept(noexcept(const_reference_t{std::declval< Cur const &>()}))
 
basic_iteratoroperator* () noexcept
 
basic_iteratoroperator++ ()
 
basic_iteratoroperator++ () noexcept
 
basic_iterator operator++ (int)
 
void operator++ (int)
 
basic_iteratoroperator+= (difference_type n)
 
basic_iteratoroperator-- ()
 
basic_iterator operator-- (int)
 
basic_iteratoroperator-= (difference_type n)
 
template<typename C = Cur, requires = (detail::HasCursorArrow<C>())>
constexpr auto operator-> () const noexcept(noexcept(range_access::arrow(std::declval< C const &>()))) -> detail::cursor_arrow_t< C >
 
template<typename C = Cur, requires = (!detail::HasCursorArrow<Cur>() && detail::ReadableCursor<Cur>() && std::is_lvalue_reference<const_reference_t>::value && Same<typename detail::iterator_associated_types_base<C>::value_type, uncvref_t<const_reference_t>>())>
constexpr meta::_t< std::add_pointer< const_reference_t > > operator-> () const noexcept(noexcept(*std::declval< basic_iterator const &>()))
 
template<typename T , requires = (!Same<detail::decay_t<T>, basic_iterator>() && !detail::HasCursorNext<Cur>() && detail::WritableCursor<Cur, T>())>
basic_iteratoroperator= (T &&t) noexcept(noexcept(std::declval< Cur &>().write(static_cast< T &&>(t))))
 
template<typename T , requires = (!Same<detail::decay_t<T>, basic_iterator>() && !detail::HasCursorNext<Cur>() && detail::WritableCursor<Cur const, T>())>
basic_iterator const & operator= (T &&t) const noexcept(noexcept(std::declval< Cur const &>().write(static_cast< T &&>(t))))
 
const_reference_t operator[] (difference_type n) const
 

Methods

◆ operator+ [1/2]

template<typename Cur>
basic_iterator operator+ ( basic_iterator< Cur >  left,
difference_type  n 
)
friend
Precondition
detail::RandomAccessCursor<Cur>()

◆ operator+ [2/2]

template<typename Cur>
basic_iterator operator+ ( difference_type  n,
basic_iterator< Cur >  right 
)
friend
Precondition
detail::RandomAccessCursor<Cur>()

◆ operator-

template<typename Cur>
basic_iterator operator- ( basic_iterator< Cur >  left,
difference_type  n 
)
friend
Precondition
detail::RandomAccessCursor<Cur>()

◆ operator<

template<typename Cur>
bool operator< ( basic_iterator< Cur > const &  left,
basic_iterator< Cur > const &  right 
)
friend
Precondition
detail::SizedCursorSentinel<Cur Cur>())

◆ operator<=

template<typename Cur>
bool operator<= ( basic_iterator< Cur > const &  left,
basic_iterator< Cur > const &  right 
)
friend
Precondition
detail::SizedCursorSentinel<Cur Cur>())

◆ operator>

template<typename Cur>
bool operator> ( basic_iterator< Cur > const &  left,
basic_iterator< Cur > const &  right 
)
friend
Precondition
detail::SizedCursorSentinel<Cur Cur>())

◆ operator>=

template<typename Cur>
bool operator>= ( basic_iterator< Cur > const &  left,
basic_iterator< Cur > const &  right 
)
friend
Precondition
detail::SizedCursorSentinel<Cur Cur>())

Member Function Documentation

◆ operator*() [1/4]

template<typename Cur>
constexpr const_reference_t ranges::v3::basic_iterator< Cur >::operator* ( ) const
noexcept
Precondition
detail::ReadableCursor<Cur>() && !detail::is_writable_cursor<Cur>()

◆ operator*() [2/4]

template<typename Cur>
reference_t ranges::v3::basic_iterator< Cur >::operator* ( )
noexcept
Precondition
detail::HasCursorNext<Cur>() && detail::is_writable_cursor<Cur>()

◆ operator*() [3/4]

template<typename Cur>
constexpr const_reference_t ranges::v3::basic_iterator< Cur >::operator* ( ) const
noexcept
Precondition
detail::HasCursorNext<Cur>() && detail::is_writable_cursor<Cur const>()

◆ operator*() [4/4]

template<typename Cur>
basic_iterator& ranges::v3::basic_iterator< Cur >::operator* ( )
noexcept
Precondition
!detail::HasCursorNext<Cur>()

◆ operator++() [1/4]

template<typename Cur>
basic_iterator& ranges::v3::basic_iterator< Cur >::operator++ ( )
Precondition
detail::HasCursorNext<Cur>()

References ranges::v3::next.

◆ operator++() [2/4]

template<typename Cur>
basic_iterator& ranges::v3::basic_iterator< Cur >::operator++ ( )
noexcept
Precondition
!detail::HasCursorNext<Cur>()

◆ operator++() [3/4]

template<typename Cur>
basic_iterator ranges::v3::basic_iterator< Cur >::operator++ ( int  )
Precondition
!Same<range_access::InputCursor detail::cursor_concept_t<Cur>>())

◆ operator++() [4/4]

template<typename Cur>
void ranges::v3::basic_iterator< Cur >::operator++ ( int  )
Precondition
Same<range_access::InputCursor detail::cursor_concept_t<Cur>>())

◆ operator+=()

template<typename Cur>
basic_iterator& ranges::v3::basic_iterator< Cur >::operator+= ( difference_type  n)
Precondition
detail::RandomAccessCursor<Cur>()

References ranges::v3::advance.

◆ operator--() [1/2]

template<typename Cur>
basic_iterator& ranges::v3::basic_iterator< Cur >::operator-- ( )
Precondition
detail::BidirectionalCursor<Cur>()

References ranges::v3::prev.

◆ operator--() [2/2]

template<typename Cur>
basic_iterator ranges::v3::basic_iterator< Cur >::operator-- ( int  )
Precondition
detail::BidirectionalCursor<Cur>()

◆ operator-=()

template<typename Cur>
basic_iterator& ranges::v3::basic_iterator< Cur >::operator-= ( difference_type  n)
Precondition
detail::RandomAccessCursor<Cur>()

References ranges::v3::advance.

◆ operator[]()

template<typename Cur>
const_reference_t ranges::v3::basic_iterator< Cur >::operator[] ( difference_type  n) const
Precondition
detail::RandomAccessCursor<Cur>()