ISource::accept Method

ISource::accept Method

When overridden in a derived class, accepts a message that was offered by this ISource block, transferring ownership to the caller.

virtual message<_Type> * accept(
   runtime_object_identity _MsgId,
   ITarget<_Type> * _PTarget
) = 0;


The runtime_object_identity of the offered message object.


A pointer to the target block that is calling the accept method.

A pointer to the message that the caller now has ownership of.

The accept method is called by a target while a message is being offered by this ISource block. The message pointer returned may be different from the one passed into the propagate method of the ITarget block, if this source decides to make a copy of the message.

Header: agents.h

Namespace: Concurrency

Community Additions

© 2016 Microsoft