Into

Modules

Documentation

classPiiInputController

#include <PiiInputController.h>

An interface for classes that receive objects from input sockets.

Inherited by PiiOperationProcessor, PiiProbeInput, PiiProxySocket

Description

Input controllers can implement any imaginable object passing mechanisms. One must make sure that operations connected to each other are driven by compatible input controllers. For example, any operation connected to an operation derived from PiiDefaultOperation must be able to handle synchronization tags and stop tags.

Constructors and destructor

virtual

Public member functions

virtual bool
( )  = 0

Activate any functionality that should be performed when a new object arrives into an input.

Function details

  • virtual ~PiiInputController

    ()
    [virtual]
  • virtual bool tryToReceive

    ( )
    [pure virtual]

    Activate any functionality that should be performed when a new object arrives into an input.

    This method is called by an input socket whenever a new object is received on it.

    Note that the function may not throw exceptions. If your implementation passes the incoming objects right away, you must catch the exceptions thrown by PiiOutputSocket::emitObject(), for example.

    Parameters
    sender

    a pointer to the socket that received the object

    object

    the object that was received

    Returns

    true if the object was accepted, false otherwise. Typically, an object is accepted if there is no blocking object in sender by calling PiiInputSocket::receive(). Note that true should be returned whenever the object is accepted for processing, even if the processing itself will fail.

Notes (0)

Add a note

Not a single note added yet. Be the first, add yours.