target_block Class

The target_block class is an abstract base class that provides basic link management functionality and error checking for target only blocks.

template<
   class _SourceLinkRegistry,
   class _MessageProcessorType = ordered_message_processor<typename _SourceLinkRegistry::type::source_type>
>
class target_block : public ITarget<typename _SourceLinkRegistry::type::source_type>;

Parameters

  • _SourceLinkRegistry
    The link registry to be used for holding the source links.

  • _MessageProcessorType
    The processor type for message processing.

Members

Public Typedefs

Name

Description

source_iterator

The type of the iterator for the source_link_manager for this target_block object.

Public Constructors

Name

Description

target_block::target_block Constructor

Constructs a target_block object.

target_block::~target_block Destructor

Destroys the target_block object.

Public Methods

Name

Description

target_block::propagate Method

Asynchronously passes a message from a source block to this target block.

target_block::send Method

Synchronously passes a message from a source block to this target block.

Protected Methods

Name

Description

target_block::async_send Method

Asynchronously sends a message for processing.

target_block::decline_incoming_messages Method

Indicates to the block that new messages should be declined.

target_block::enable_batched_processing Method

Enables batched processing for this block.

target_block::initialize_target Method

Initializes the base object. Specifically, the message_processor object needs to be initialized.

target_block::link_source Method

Links a specified source block to this target_block object.

target_block::process_input_messages Method

Processes messages that are received as inputs.

target_block::process_message Method

When overridden in a derived class, processes a message that was accepted by this target_block object.

target_block::propagate_message Method

When overridden in a derived class, this method asynchronously passes a message from an ISource block to this target_block object. It is invoked by the propagate method, when called by a source block.

target_block::register_filter Method

Registers a filter method that will be invoked on every message received.

target_block::remove_sources Method

Unlinks all sources after waiting for outstanding asynchronous send operations to complete.

target_block::send_message Method

When overridden in a derived class, this method synchronously passes a message from an ISource block to this target_block object. It is invoked by the send method, when called by a source block.

target_block::sync_send Method

Synchronously send a message for processing.

target_block::unlink_source Method

Unlinks a specified source block from this target_block object.

target_block::unlink_sources Method

Unlinks all source blocks from this target_block object. (Overrides ITarget::unlink_sources.)

target_block::wait_for_async_sends Method

Waits for all asynchronous propagations to complete.

Inheritance Hierarchy

ITarget

target_block

Requirements

Header: agents.h

Namespace: concurrency

See Also

Reference

concurrency Namespace

ITarget Class