STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Types | Public Member Functions | Static Public Attributes | Private Attributes | List of all members
Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind > Class Template Reference

#include <ppl.h>

Public Types

typedef std::iterator_traits< _Forward_iterator >::value_type value_type
 

Public Member Functions

 _Iterator_helper ()
 
size_t _Populate (_Forward_iterator &_First, _Forward_iterator _Last)
 
void _Populate (_Forward_iterator &_First, size_t _Length)
 
void _Store (const value_type &_Elem, size_t _Index) const
 
std::iterator_traits< _Forward_iterator >::reference _Load (size_t _Index) const
 

Static Public Attributes

static const size_t _Size = 1024
 

Private Attributes

std::iterator_traits< _Forward_iterator >::pointer _M_element_array [_Size]
 

Member Typedef Documentation

template<typename _Forward_iterator, typename _Iterator_kind>
typedef std::iterator_traits<_Forward_iterator>::value_type Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::value_type

Constructor & Destructor Documentation

template<typename _Forward_iterator, typename _Iterator_kind>
Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_Iterator_helper ( )
inline
3588  {
3589  static_assert(!std::is_same<_Iterator_kind, std::input_iterator_tag>::value
3590  && !std::is_same<_Iterator_kind, std::output_iterator_tag>::value,
3591  "iterator can not be input_iterator or output_iterator.");
3592  }

Member Function Documentation

template<typename _Forward_iterator, typename _Iterator_kind>
std::iterator_traits<_Forward_iterator>::reference Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_Load ( size_t  _Index) const
inline
3622  {
3623  return *(_M_element_array[_Index]);
3624  }
std::iterator_traits< _Forward_iterator >::pointer _M_element_array[_Size]
Definition: ppl.h:3627
template<typename _Forward_iterator, typename _Iterator_kind>
size_t Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_Populate ( _Forward_iterator &  _First,
_Forward_iterator  _Last 
)
inline
3595  {
3596  size_t _Length = 0;
3597  static_assert(std::is_lvalue_reference<decltype(*_First)>::value, "lvalue required for forward iterator operator *");
3598 
3599  for (size_t _Index=0; (_Index < _Size) && (_First != _Last); _Index++)
3600  {
3601  // We only support l-value here, so it's safe
3602  _M_element_array[_Length++] = &(*_First++);
3603  }
3604 
3605  return _Length;
3606  }
static const size_t _Size
Definition: ppl.h:3584
std::iterator_traits< _Forward_iterator >::pointer _M_element_array[_Size]
Definition: ppl.h:3627
_FwdIt _Last
Definition: algorithm:1936
template<typename _Forward_iterator, typename _Iterator_kind>
void Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_Populate ( _Forward_iterator &  _First,
size_t  _Length 
)
inline
3609  {
3610  for (size_t _Index=0; _Index < _Length; _Index++)
3611  {
3612  _M_element_array[_Index] = &(*_First++);
3613  }
3614  }
std::iterator_traits< _Forward_iterator >::pointer _M_element_array[_Size]
Definition: ppl.h:3627
template<typename _Forward_iterator, typename _Iterator_kind>
void Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_Store ( const value_type _Elem,
size_t  _Index 
) const
inline
3617  {
3618  *(_M_element_array[_Index]) = _Elem;
3619  }
std::iterator_traits< _Forward_iterator >::pointer _M_element_array[_Size]
Definition: ppl.h:3627

Member Data Documentation

template<typename _Forward_iterator, typename _Iterator_kind>
std::iterator_traits<_Forward_iterator>::pointer Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_M_element_array[_Size]
private
template<typename _Forward_iterator, typename _Iterator_kind>
const size_t Concurrency::_Iterator_helper< _Forward_iterator, _Iterator_kind >::_Size = 1024
static

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