RTI Routing Service  Version 6.0.1
 All Data Structures Files Functions Typedefs Enumerations Enumerator Groups Pages
rti::routing::processor::Processor Class Referenceabstract

Processor interface definition. Provides a way to process Route events and control the data forwarding process. More...

#include <Processor.hpp>

Inheritance diagram for rti::routing::processor::Processor:
rti::routing::UpdatableEntity rti::routing::processor::NoOpProcessor

Public Member Functions

virtual void on_input_enabled (Route &route, rti::routing::processor::Input &input)=0
 Notification of the INPUT_ENABLED event.
 
virtual void on_input_disabled (Route &route, rti::routing::processor::Input &input)=0
 Notification of the Input disabled event.
 
virtual void on_output_enabled (Route &route, rti::routing::processor::Output &output)=0
 Notification of the Output enabled event.
 
virtual void on_output_disabled (Route &route, rti::routing::processor::Output &output)=0
 Notification of the Output disabled event.
 
virtual void on_start (Route &route)=0
 Notification of the Route started event.
 
virtual void on_stop (Route &route)=0
 Notification of the Route stopped event.
 
virtual void on_run (Route &route)=0
 Notification of the Route RUN event.
 
virtual void on_pause (Route &route)=0
 Notification of the Route stopped event.
 
virtual void on_periodic_action (Route &route)=0
 Notification of the Route periodic action event.
 
virtual void on_data_available (Route &route)=0
 Notification of the Route DATA_AVAILABLE event.
 
virtual ~Processor ()
 Virtual destructor.
 
- Public Member Functions inherited from rti::routing::UpdatableEntity
virtual void update (const std::map< std::string, std::string > &properties)
 Updates a pluggable entity.
 
virtual ~UpdatableEntity ()
 Virtual destructor.
 

Detailed Description

Processor interface definition. Provides a way to process Route events and control the data forwarding process.

A Processor receives event notifications from its Route owner in the form of operation callbacks. Each event occurrence will be dispatched to the Processor by calling the corresponding method.

Each dispatching method has a signature according to the event kind and data it is associated with. Each event is associated with a Route state; hence limitations and constraints may apply individually to each method.

Note that throwing an exception while processing any of the event notifications is allowed. In this situation, the Route owner will reject the events and none of the associated post conditions will be applied, including state transitions.

Multi-threading safety:
Partially Safe All operations on a concrete Processor object are safe and always serialized on a given Session. Operations on different Processor objects may be called concurrently if they belong to different Routes.
See Also
ProcessorPlugin
Route

Constructor & Destructor Documentation

virtual rti::routing::processor::Processor::~Processor ( )
inlinevirtual

Virtual destructor.

Member Function Documentation

virtual void rti::routing::processor::Processor::on_input_enabled ( Route route,
rti::routing::processor::Input input 
)
pure virtual

Notification of the INPUT_ENABLED event.

This operation is called when an Input enabled event occurs that affects any of the inputs contained in the owner Route.

This operation is called right after the affected Input has been enabled.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../sessions/Session/routes/Route/inputs/Input1|ENABLE] stream=Example
Parameters
[in]routeRoute owner that contains this Processor.
[in]inputThe just enabled Input.
Exceptions
std::exceptionThrowing an error in this operation will cause the input to be automatically disabled right after.
virtual void rti::routing::processor::Processor::on_input_disabled ( Route route,
rti::routing::processor::Input input 
)
pure virtual

Notification of the Input disabled event.

This operation is called when an INPUT_DISABLED event occurs that affects any of the inputs contained in the owner Route.

This operation is called right before the affected Input is disabled.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../sessions/Session/routes/Route/inputs/Input1|DISABLE] stream=Example
Parameters
[in]routeRoute owner that contains this Processor.
[in]inputThe Input about to be disabled.
Exceptions
std::exceptionThrowing an error in this operation will cause the input to remain enabled.
virtual void rti::routing::processor::Processor::on_output_enabled ( Route route,
rti::routing::processor::Output output 
)
pure virtual

Notification of the Output enabled event.

This operation is called when an OUTPUT_DISABLED event occurs that affects any of the outputs contained in the owner Route.

This operation is called right after the affected Output has been enabled.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../sessions/Session/routes/Route/outputs/Output1|ENABLE] stream=Example
Parameters
[in]routeRoute owner that contains this Processor.
[in]outputThe just enabled output.
Exceptions
std::exceptionThrowing an error in this operation will cause the output to be automatically disabled right after.
virtual void rti::routing::processor::Processor::on_output_disabled ( Route route,
rti::routing::processor::Output output 
)
pure virtual

Notification of the Output disabled event.

This operation is called when an OUTPUT_DISABLED event occurs that affects any of the outputs contained in the owner Route.

This operation is called right before the affected Output is disabled.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../sessions/Session/routes/Route/outputs/Output1|DISABLE] stream=Example
Parameters
[in]routeRoute owner that contains this Processor.
[in]outputThe Output about to be disabled.
Exceptions
std::exceptionThrowing an error in this operation will cause the output to remain enabled.
virtual void rti::routing::processor::Processor::on_start ( Route route)
pure virtual

Notification of the Route started event.

This operation is called right before the Route enters the STARTED state. At the time this operation is called, all the inputs and outputs within the Route are enabled.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../domain_routes/DomainRoute/sessions/Session/routes/Route|START]
Parameters
[in]routeRoute owner that contains this Processor.
Exceptions
std::exceptionThrowing an error in this operation will cause the route to remain STOPPED.
virtual void rti::routing::processor::Processor::on_stop ( Route route)
pure virtual

Notification of the Route stopped event.

This operation is called right before the Route enters the STOPPED state. At the time this operation is called, all the inputs and outputs within the Route are still enabled.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../domain_routes/DomainRoute/sessions/Session/routes/Route|STOP]
Parameters
[in]routeRoute owner that contains this Processor.
Exceptions
std::exceptionThrowing an error in this operation will cause the route to remain STARTED.
virtual void rti::routing::processor::Processor::on_run ( Route route)
pure virtual

Notification of the Route RUN event.

This operation is called right before the Route enters the RUNNING state. This operation is called after the Route went to STARTED after a successful notification to this Processor,

Note
If the Route was manually paused before via an Administration call, this operation will not be called until a manual run operation is performed.

A Routing Service running instance will produce a log indicating the occurrence of the event. For example:

[.../domain_routes/DomainRoute/sessions/Session/routes/Route|RUN]
Parameters
[in]routeRoute owner that contains this Processor.
Exceptions
std::exceptionThrowing an error in this operation will cause the route to remain PAUSED.
virtual void rti::routing::processor::Processor::on_pause ( Route route)
pure virtual

Notification of the Route stopped event.

This operation is called right before the Route enters the PAUSED state. At the time this operation is called, all the inputs and outputs within the Route are still enabled.

A Routing Service running instance will produce a log indicating the occurrence of the event. For example:

[.../domain_routes/DomainRoute/sessions/Session/routes/Route|PAUSE]
Parameters
[in]routeRoute owner that contains this Processor.
Exceptions
std::exceptionThrowing an error in this operation will cause the route to remain RUNNING.
virtual void rti::routing::processor::Processor::on_periodic_action ( Route route)
pure virtual

Notification of the Route periodic action event.

This operation is called periodically at the rate specified in the parent Session of the Route owner.

Periodic notifications can occur only while the Route is in the RUNNING state.

Implementations are allowed to access any of the Input and Output of the owner Route to read and write data, respectively.

A Routing Service running instance will produce a log indicating the occurrence of the event. For example:

[.../domain_routes/DomainRoute/sessions/Session/routes/Route] process event=PERODIC_ACTION
Parameters
[in]routeRoute owner that contains this Processor.
Exceptions
std::exceptionThrowing an error in this operation will produce a log message without affecting the Route state and notifications of this event to this Processor will keep occurring.
virtual void rti::routing::processor::Processor::on_data_available ( Route route)
pure virtual

Notification of the Route DATA_AVAILABLE event.

This operation is called each time any of the inputs contained in the owner Route is notified about new data. Notifications of this event can occur only while the Route is in the RUNNING state.

Implementations are allowed to access any of the Input and Output of the owner Route to read and write data, respectively.

A running Routing Service instance will produce a log indicating the occurrence of the event. For example:

[.../domain_routes/DomainRoute/sessions/Session/routes/Route] process event=DATA_ON_INPUTS
Parameters
[in]routeRoute owner that contains this Processor.
Exceptions
std::exceptionThrowing an error in this operation will produce a log message without affecting the Route state and notifications of this event to this Processor will keep occurring.

RTI Routing Service Version 6.0.1 Copyright © Sun Nov 17 2019 Real-Time Innovations, Inc