rpa::transform_args< RngIn, RngOut, UnaOp, RetType > Class Template Reference

For storing the argument of the algorithm, as given by the calling program. More...

#include <transform.h>

Inheritance diagram for rpa::transform_args< RngIn, RngOut, UnaOp, RetType >:

rpa::transform_t< Range, ItOut, UnaOp > rpa::transform_t< RngIn, rpa::range_outp< rpa::obuf_iterator< IterOut, Buffer, IterBuf, void > >, Ftor > rpa::transform_t< rpa::range_void, SliceOut::iterator, Ftor > rpa::transform_seq_size_jump< RngIn, RngOut, Ftor >::functor_t rpa::transform_seq_size_jump< RngIn, range_outp< obuf_iterator< IterOut, Buffer, IterBuf, void > >, Ftor >::functor_t List of all members.

Public Types

typedef RetType result_type
typedef RngIn range_in_t
typedef RngOut range_out_t
typedef UnaOp args_functor
typedef RngOut::iterator internal_result_type
 The same as 'return_type' except for cases such as obuf_iterator.

Public Member Functions

 transform_args (const RngIn &aRngIn, const RngOut &aRngOut, const UnaOp &aFunc)
template<class SubRetType>
void reduce (const SubRetType &refVal, seqnum_t idxVal)
 Most of times the parameter is RngOut::iterator.
const RngOut & output_interval (void) const
const result_typeresult (void) const
const result_typeoperator() (void)
 Plain sequential execution.
template<class Thr>
threadify_t< UnaOp, Thr
>::functor_type 
threadize (Thr &refThr)
 Helper for wrapping a functor and its thread.

Public Attributes

RngIn _seqIn
RngOut _seqOut
UnaOp _Func

Private Attributes

seqnum_t _numReduc
 If it is negative, it means that no result is available.

Detailed Description

template<class RngIn, class RngOut, class UnaOp, class RetType>
class rpa::transform_args< RngIn, RngOut, UnaOp, RetType >

For storing the argument of the algorithm, as given by the calling program.


Member Typedef Documentation

template<class RngIn, class RngOut, class UnaOp, class RetType>
typedef UnaOp rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::args_functor

template<class RngIn, class RngOut, class UnaOp, class RetType>
typedef RngOut::iterator rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::internal_result_type

The same as 'return_type' except for cases such as obuf_iterator.

template<class RngIn, class RngOut, class UnaOp, class RetType>
typedef RngIn rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::range_in_t

template<class RngIn, class RngOut, class UnaOp, class RetType>
typedef RngOut rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::range_out_t

template<class RngIn, class RngOut, class UnaOp, class RetType>
typedef RetType rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::result_type

Reimplemented in rpa::transform_seq_size_jump< RngIn, range_outp< obuf_iterator< IterOut, Buffer, IterBuf, void > >, Ftor >::functor_t, rpa::transform_t< Range, ItOut, UnaOp >, rpa::transform_t< rpa::range_void, SliceOut::iterator, Ftor >, rpa::transform_t< RngIn, rpa::range_outp< rpa::obuf_iterator< IterOut, Buffer, IterBuf, Mutex > >, Ftor >, and rpa::transform_t< RngIn, rpa::range_outp< rpa::obuf_iterator< IterOut, Buffer, IterBuf, void > >, Ftor >.


Constructor & Destructor Documentation

template<class RngIn, class RngOut, class UnaOp, class RetType>
rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::transform_args ( const RngIn &  aRngIn,
const RngOut &  aRngOut,
const UnaOp &  aFunc 
) [inline]


Member Function Documentation

template<class RngIn, class RngOut, class UnaOp, class RetType>
const result_type& rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::operator() ( void   )  [inline]

Plain sequential execution.

Used when there is no or one sub-thread, or when a sub-thread executes the algorithm for one slice.

Beware : _seqOut.begin() and _seqOut.result() may not have the same type : If the output iterator is an obuf_iterator, the return type is too. But internally, another data type is used. This is why we separate these two types.

Beware that 'result' may not have the same datatype as 'begin'.

This will match, for example, two very different cases :

template<class RngIn, class RngOut, class UnaOp, class RetType>
const RngOut& rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::output_interval ( void   )  const [inline]

template<class RngIn, class RngOut, class UnaOp, class RetType>
template<class SubRetType>
void rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::reduce ( const SubRetType &  refVal,
seqnum_t  idxVal 
) [inline]

Most of times the parameter is RngOut::iterator.

template<class RngIn, class RngOut, class UnaOp, class RetType>
const result_type& rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::result ( void   )  const [inline]

template<class RngIn, class RngOut, class UnaOp, class RetType>
template<class Thr>
threadify_t< UnaOp,Thr >::functor_type rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::threadize ( Thr &  refThr  )  [inline]

Helper for wrapping a functor and its thread.


Member Data Documentation

template<class RngIn, class RngOut, class UnaOp, class RetType>
UnaOp rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::_Func

template<class RngIn, class RngOut, class UnaOp, class RetType>
seqnum_t rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::_numReduc [private]

If it is negative, it means that no result is available.

template<class RngIn, class RngOut, class UnaOp, class RetType>
RngIn rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::_seqIn

template<class RngIn, class RngOut, class UnaOp, class RetType>
RngOut rpa::transform_args< RngIn, RngOut, UnaOp, RetType >::_seqOut


The documentation for this class was generated from the following file:
Generated on Tue Sep 25 10:20:33 2007 for rpa by  doxygen 1.4.7