Lumiera 0.pre.04
»edit your freedom«
Loading...
Searching...
No Matches
IndexAccessCore< PTR > Struct Template Reference

#include "lib/index-iter.hpp"

Description

template<typename PTR>
struct lib::iter::IndexAccessCore< PTR >

Implementation of a »IterStateCore« to access the container through an embedded index variable.

Definition at line 46 of file index-iter.hpp.

Public Types

using ResVal = decltype(data_->operator[](0))
 
using value_type = meta::RefTraits< ResVal >::Value
 
using reference = meta::RefTraits< ResVal >::Reference
 
using IterWrapper = lib::IterStateWrapper< IndexAccessCore >
 

Public Attributes

PTR data_ {}
 
size_t idx_ {0}
 

Public Member Functions

bool checkPoint () const
 
reference yield () const
 
void iterNext ()
 
bool isValidIDX (size_t idx) const
 

Friends

bool operator== (IndexAccessCore const &c1, IndexAccessCore const &c2)
 
bool operator!= (IndexAccessCore const &c1, IndexAccessCore const &c2)
 

Member Typedef Documentation

◆ ResVal

template<typename PTR >
using ResVal = decltype(data_->operator[](0))

Definition at line 51 of file index-iter.hpp.

◆ value_type

template<typename PTR >
using value_type = meta::RefTraits<ResVal>::Value

Definition at line 53 of file index-iter.hpp.

◆ reference

template<typename PTR >
using reference = meta::RefTraits<ResVal>::Reference

Definition at line 54 of file index-iter.hpp.

◆ IterWrapper

template<typename PTR >
using IterWrapper = lib::IterStateWrapper<IndexAccessCore>

Definition at line 82 of file index-iter.hpp.

Member Function Documentation

◆ checkPoint()

template<typename PTR >
bool checkPoint ( ) const
inline

Definition at line 57 of file index-iter.hpp.

References IndexAccessCore< PTR >::idx_, and IndexAccessCore< PTR >::isValidIDX().

+ Here is the call graph for this function:

◆ yield()

template<typename PTR >
reference yield ( ) const
inline

Definition at line 63 of file index-iter.hpp.

References IndexAccessCore< PTR >::data_, and IndexAccessCore< PTR >::idx_.

◆ iterNext()

template<typename PTR >
void iterNext ( )
inline

Definition at line 69 of file index-iter.hpp.

References IndexAccessCore< PTR >::idx_.

◆ isValidIDX()

template<typename PTR >
bool isValidIDX ( size_t  idx) const
inline

Definition at line 76 of file index-iter.hpp.

References IndexAccessCore< PTR >::data_.

Referenced by IndexAccessCore< PTR >::checkPoint().

+ Here is the caller graph for this function:

Member Data Documentation

◆ data_

template<typename PTR >
PTR data_ {}

◆ idx_

template<typename PTR >
size_t idx_ {0}

Friends And Related Symbol Documentation

◆ operator==

template<typename PTR >
bool operator== ( IndexAccessCore< PTR > const &  c1,
IndexAccessCore< PTR > const &  c2 
)
friend

Definition at line 85 of file index-iter.hpp.

◆ operator!=

template<typename PTR >
bool operator!= ( IndexAccessCore< PTR > const &  c1,
IndexAccessCore< PTR > const &  c2 
)
friend

Definition at line 89 of file index-iter.hpp.

+ Collaboration diagram for IndexAccessCore< PTR >:

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