This documentation is archived and is not being maintained.

transformer::transformer Constructor

Constructs a transformer messaging block.

transformer(
   _Transform_method const& _Func,
   ITarget<_Output> * _PTarget = NULL
);
transformer(
   _Transform_method const& _Func,
   ITarget<_Output> * _PTarget,
   filter_method const& _Filter
);
transformer(
   Scheduler& _PScheduler,
   _Transform_method const& _Func,
   ITarget<_Output> * _PTarget = NULL
);
transformer(
   Scheduler& _PScheduler,
   _Transform_method const& _Func,
   ITarget<_Output> * _PTarget,
   filter_method const& _Filter
);
transformer(
   ScheduleGroup& _PScheduleGroup,
   _Transform_method const& _Func,
   ITarget<_Output> * _PTarget = NULL
);
transformer(
   ScheduleGroup& _PScheduleGroup,
   _Transform_method const& _Func,
   ITarget<_Output> * _PTarget,
   filter_method const& _Filter
);

_Func

A function that will be invoked for each accepted message.

_PTarget

A pointer to a target block to link with the transformer.

_Filter

A filter function which determines whether offered messages should be accepted.

_PScheduler

The Scheduler object within which the propagation task for the transformer messaging block is scheduled.

_PScheduleGroup

The ScheduleGroup object within which the propagation task for the transformer messaging block is scheduled. The Scheduler object used is implied by the schedule group.

The runtime uses the default scheduler if you do not specify the _PScheduler or _PScheduleGroup parameters.

The type _Transform_method is a functor with signature _Output (_Input const &) which is invoked by this transformer messaging block to process a message.

The type filter_method is a functor with signature bool (_Input const &) which is invoked by this transformer messaging block to determine whether or not it should accept an offered message.

Header: agents.h

Namespace: Concurrency

Show: