ApplyToRange

Files CCore/inc/algon/ApplyToRange.h CCore/src/algon/ApplyToRange.cpp

ApplyToRange() applies a functor to a set of elements. This algorithm uses the Functor Init Pattern. The first argument is a Cursor, the second is a functor initializer.


template <class R,class FuncInit>
void Algon::ApplyToRange(R r,FuncInit func_init)
 {
  FunctorTypeOf<FuncInit> func(func_init);
  
  for(; +r ;++r) func(*r);
 }