Go to the documentation of this file.00001 #ifndef OPENTISSUE_CORE_CONTAINERS_GRID_UTIL_GRID_TRANSFORM_H
00002 #define OPENTISSUE_CORE_CONTAINERS_GRID_UTIL_GRID_TRANSFORM_H
00003
00004
00005
00006
00007
00008
00009
00010 #include <OpenTissue/configuration.h>
00011
00012 namespace OpenTissue
00013 {
00014 namespace grid
00015 {
00042 template<typename input_iterator, typename output_iterator ,typename function_type>
00043 inline void transform(input_iterator in_begin,input_iterator in_end, output_iterator out_begin, function_type func)
00044 {
00045 for ( input_iterator i = in_begin; i != in_end; ++i,++out_begin)
00046 *out_begin = func( i );
00047 }
00048
00049
00050
00051 }
00052 }
00053
00054
00055 #endif