![]() |
Dataflow Runtime API
3.0.3.0
|
Abstract base class for an ActivePart. More...
#include <Imt.Base.Dff.ActiveParts/ActivePartAbs.h>
Public Member Functions | |
| ActivePartAbs (const imt::base::dff::runtime::RuntimePriority::Id priority, const imt::base::dff::runtime::ExecutableConfiguration executableConfiguration=imt::base::dff::runtime::ExecutableConfiguration()) | |
| Constructor. More... | |
| virtual | ~ActivePartAbs (void) |
| Destructor. More... | |
| virtual const imt::base::dff::runtime::ExecutableConfiguration & | getExecutableConfiguration (void) const |
| virtual imt::base::dff::runtime::RuntimePriority::Id | getPriority (void) const |
| void | initialize (void) |
| Initialize the active part. More... | |
| void | start (void) |
| Start the active part. More... | |
| bool | isInitialized (void) const |
| Check if active part is initialized. More... | |
| bool | isStarted (void) const |
| Check if active part is started. More... | |
| virtual void | startOneShotTimer (imt::base::dff::runtime::RuntimeTimer::TimerHandle &timerToStart, const uint32_t timerTicksMs) const |
| Starts or restarts the given one shot timer for this active part. More... | |
| virtual void | startPeriodicTimer (imt::base::dff::runtime::RuntimeTimer::TimerHandle &timerToStart, const uint32_t intervalMs) const |
| Start a periodic timer for this active part. More... | |
| virtual void | killTimer (imt::base::dff::runtime::RuntimeTimer::TimerHandle &timerToKill) const |
| Kill the given timer (if required). More... | |
Public Member Functions inherited from imt::base::dff::runtime::ExecutableIfc | |
| virtual | ~ExecutableIfc (void) |
| Destructor. More... | |
| virtual void | execute (const uint16_t protocolIdentifier, imt::base::core::serialization::Deserializer &deserializer)=0 |
| One-Shot function which is called once a message is ready to be processed. More... | |
Public Member Functions inherited from imt::base::dff::runtime::TimerServiceIfc | |
| virtual | ~TimerServiceIfc (void) |
| Destructor. More... | |
Public Attributes | |
| const PortInput & | PortIn |
| Input Port of the active part (as a public visible read-only reference). More... | |
Protected Member Functions | |
| virtual void | onInitialize (void)=0 |
| 1st step = called by initialize(). More... | |
| virtual void | onStart (void)=0 |
| 2nd step = called by start(). More... | |
Abstract base class for an ActivePart.
ActiveParts are objects which encapsulate their private state, behavior and data. They communicate to each other solely by exchanging messages.
|
explicit |
Constructor.
| priority | Priority of the active part. |
| executableConfiguration | Executable configuration |
|
virtual |
Destructor.
|
virtual |
Implements imt::base::dff::runtime::ExecutableIfc.
|
virtual |
Implements imt::base::dff::runtime::ExecutableIfc.
| void imt::base::dff::activeparts::ActivePartAbs::initialize | ( | void | ) |
Initialize the active part.
Register in runtime and create internal connections.
| bool imt::base::dff::activeparts::ActivePartAbs::isInitialized | ( | void | ) | const |
Check if active part is initialized.
| bool imt::base::dff::activeparts::ActivePartAbs::isStarted | ( | void | ) | const |
Check if active part is started.
|
virtual |
Kill the given timer (if required).
| timerToKill | Handle of the timer to be killed. |
Implements imt::base::dff::runtime::TimerServiceIfc.
|
protectedpure virtual |
1st step = called by initialize().
Initialize the active part and if necessary the hardware peripherals. No messages should be sent at this stage, use onStart() function!
Implemented in imt::base::dff::activeparts::test::TestLoggerAP, imt::base::dff::activeparts::stm32f103hd::i2c::I2CTransactionHandlerAP, and imt::base::dff::activeparts::am3354::I2CTransactionHandlerAP.
|
protectedpure virtual |
2nd step = called by start().
Starts the active part and send all initialization messages.
Implemented in imt::base::dff::activeparts::test::TestLoggerAP, imt::base::dff::activeparts::stm32f103hd::i2c::I2CTransactionHandlerAP, and imt::base::dff::activeparts::am3354::I2CTransactionHandlerAP.
| void imt::base::dff::activeparts::ActivePartAbs::start | ( | void | ) |
Start the active part.
Here is the correct place to send the initialization messages.
|
virtual |
Starts or restarts the given one shot timer for this active part.
In case of invalid parameters, timerToStart is set to an invalid time handle.
| timerToStart | Timer to be started. |
| timerTicksMs | Timer delay in milliseconds. |
Implements imt::base::dff::runtime::TimerServiceIfc.
|
virtual |
Start a periodic timer for this active part.
In case of invalid parameters, an invalid time handle is returned.
| timerToStart | Timer to be started. |
| intervalMs | Timer period in milliseconds. |
Implements imt::base::dff::runtime::TimerServiceIfc.
| const PortInput& imt::base::dff::activeparts::ActivePartAbs::PortIn |
Input Port of the active part (as a public visible read-only reference).