![]() |
helics
2.8.1
|
#include <MessageTimer.hpp>
Inheritance diagram for helics::MessageTimer:Public Types | |
| using | time_type = decltype(std::chrono::steady_clock::now()) |
Public Member Functions | |
| MessageTimer (std::function< void(ActionMessage &&)> sFunction) | |
| int32_t | addTimerFromNow (std::chrono::nanoseconds time, ActionMessage mess) |
| int32_t | addTimer (time_type expirationTime, ActionMessage mess) |
| void | cancelTimer (int32_t index) |
| void | cancelAll () |
| void | updateTimer (int32_t timerIndex, time_type expirationTime, ActionMessage mess) |
| bool | updateTimer (int32_t timerIndex, time_type expirationTime) |
| bool | addTimeToTimer (int32_t timerIndex, std::chrono::nanoseconds time) |
| void | updateMessage (int32_t timerIndex, ActionMessage mess) |
| void | sendMessage (int32_t timerIndex) |
class containing a message timer for sending messages at particular points in time
| int32_t helics::MessageTimer::addTimer | ( | time_type | expirationTime, |
| ActionMessage | mess | ||
| ) |
add a timer and message to the queue
Referenced by addTimerFromNow().
| int32_t helics::MessageTimer::addTimerFromNow | ( | std::chrono::nanoseconds | time, |
| ActionMessage | mess | ||
| ) |
add a timer and message to the queue
References addTimer().
| bool helics::MessageTimer::addTimeToTimer | ( | int32_t | timerIndex, |
| std::chrono::nanoseconds | time | ||
| ) |
update the message time of a timer keeping its message the same the function will add time to the timer
| void helics::MessageTimer::cancelAll | ( | ) |
cancel all timers
| void helics::MessageTimer::cancelTimer | ( | int32_t | index | ) |
cancel a timer by index
| void helics::MessageTimer::sendMessage | ( | int32_t | timerIndex | ) |
execute the send function associated with a message
| void helics::MessageTimer::updateMessage | ( | int32_t | timerIndex, |
| ActionMessage | mess | ||
| ) |
update the message associated with a timer
| bool helics::MessageTimer::updateTimer | ( | int32_t | timerIndex, |
| time_type | expirationTime | ||
| ) |
update the message time of a timer keeping its message the same if the message has been sent already the message stored is invalid
| void helics::MessageTimer::updateTimer | ( | int32_t | timerIndex, |
| time_type | expirationTime, | ||
| ActionMessage | mess | ||
| ) |
update the message time of a timer and its message
1.8.17