libGimbal 0.1.0
C17-Based Extended Standard Library and Cross-Language Runtime Framework
Loading...
Searching...
No Matches
gimbal::RandomAccessIterable< CRTP, Index, Value > Class Template Reference
Inheritance diagram for gimbal::RandomAccessIterable< CRTP, Index, Value >:
gimbal::StringViewBase< String > gimbal::StringViewBase< StringView > gimbal::VectorViewBase< Vector< void * >, void * > gimbal::VectorViewBase< Vector< T >, T > gimbal::VectorViewBase< VectorView< T >, T > gimbal::String gimbal::StringView gimbal::Vector< T > gimbal::VectorView< T > gimbal::FlexibleString< ExtraStackSize > gimbal::FlexibleVector< ExtraStackSize, T >

Public Types

using iterator = RandomAccessIterator< CRTP, Index, Value, false >
 
using reverse_iterator = RandomAccessIterator< CRTP, Index, Value, true >
 
using const_iterator = RandomAccessIterator< std::add_const_t< CRTP >, Index, Value, false >
 
using reverse_const_iterator = RandomAccessIterator< std::add_const_t< CRTP >, Index, Value, true >
 

Public Member Functions

iterator begin (void)
 
auto begin (void) const
 
auto rbegin (void)
 
auto rbegin (void) const
 
iterator end (void)
 
auto end (void) const
 
auto rend (void)
 
auto rend (void) const
 
const_iterator cbegin (void) const
 
auto crbegin (void) const
 
const_iterator cend (void) const
 
auto crend (void) const
 

Detailed Description

template<typename CRTP, typename Index, typename Value>
class gimbal::RandomAccessIterable< CRTP, Index, Value >

Definition at line 217 of file gimbal_generics.hpp.

Member Typedef Documentation

◆ iterator

template<typename CRTP , typename Index , typename Value >
using gimbal::RandomAccessIterable< CRTP, Index, Value >::iterator = RandomAccessIterator<CRTP, Index, Value, false>

Definition at line 220 of file gimbal_generics.hpp.

◆ reverse_iterator

template<typename CRTP , typename Index , typename Value >
using gimbal::RandomAccessIterable< CRTP, Index, Value >::reverse_iterator = RandomAccessIterator<CRTP, Index, Value, true>

Definition at line 221 of file gimbal_generics.hpp.

◆ const_iterator

template<typename CRTP , typename Index , typename Value >
using gimbal::RandomAccessIterable< CRTP, Index, Value >::const_iterator = RandomAccessIterator<std::add_const_t<CRTP>, Index, Value, false>

Definition at line 222 of file gimbal_generics.hpp.

◆ reverse_const_iterator

template<typename CRTP , typename Index , typename Value >
using gimbal::RandomAccessIterable< CRTP, Index, Value >::reverse_const_iterator = RandomAccessIterator<std::add_const_t<CRTP>, Index, Value, true>

Definition at line 223 of file gimbal_generics.hpp.

Member Function Documentation

◆ begin() [1/2]

template<typename CRTP , typename Index , typename Value >
iterator gimbal::RandomAccessIterable< CRTP, Index, Value >::begin ( void  )
inline

Definition at line 232 of file gimbal_generics.hpp.

232{ return {*static_cast<CRTP*>(this), 0}; }

◆ begin() [2/2]

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::begin ( void  ) const
inline

Definition at line 233 of file gimbal_generics.hpp.

233{ return cbegin(); }

◆ rbegin() [1/2]

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::rbegin ( void  )
inline

Definition at line 235 of file gimbal_generics.hpp.

235{ return std::make_reverse_iterator(end()); }

◆ rbegin() [2/2]

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::rbegin ( void  ) const
inline

Definition at line 236 of file gimbal_generics.hpp.

236{ return crbegin(); }

◆ end() [1/2]

template<typename CRTP , typename Index , typename Value >
iterator gimbal::RandomAccessIterable< CRTP, Index, Value >::end ( void  )
inline

Definition at line 237 of file gimbal_generics.hpp.

237{ return iterator(*static_cast<CRTP*>(this), (Index)static_cast<const CRTP*>(this)->getElementCount_()); }

◆ end() [2/2]

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::end ( void  ) const
inline

Definition at line 238 of file gimbal_generics.hpp.

238{ return cend(); }

◆ rend() [1/2]

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::rend ( void  )
inline

Definition at line 240 of file gimbal_generics.hpp.

240{ return std::make_reverse_iterator(begin()); }

◆ rend() [2/2]

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::rend ( void  ) const
inline

Definition at line 241 of file gimbal_generics.hpp.

241{ return crend(); }

◆ cbegin()

template<typename CRTP , typename Index , typename Value >
const_iterator gimbal::RandomAccessIterable< CRTP, Index, Value >::cbegin ( void  ) const
inline

Definition at line 242 of file gimbal_generics.hpp.

242{ return {*static_cast<const CRTP*>(this), 0}; }

◆ crbegin()

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::crbegin ( void  ) const
inline

Definition at line 244 of file gimbal_generics.hpp.

244{ return std::make_reverse_iterator(cend()); }

◆ cend()

template<typename CRTP , typename Index , typename Value >
const_iterator gimbal::RandomAccessIterable< CRTP, Index, Value >::cend ( void  ) const
inline

Definition at line 245 of file gimbal_generics.hpp.

245{ return const_iterator(*static_cast<const CRTP*>(this), (Index)static_cast<const CRTP*>(this)->getElementCount_()); }

◆ crend()

template<typename CRTP , typename Index , typename Value >
auto gimbal::RandomAccessIterable< CRTP, Index, Value >::crend ( void  ) const
inline

Definition at line 247 of file gimbal_generics.hpp.

247{ return std::make_reverse_iterator(cbegin()); }

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