helics
3.5.2
|
#include <AsyncTimeCoordinator.hpp>
Public Member Functions | |
virtual bool | updateTimeFactors () override |
virtual MessageProcessingResult | checkExecEntry (GlobalFederateId triggerFed=GlobalFederateId{}) override |
virtual std::string | printTimeStatus () const override |
virtual void | generateDebuggingTimeInfo (Json::Value &base) const override |
virtual Time | getNextTime () const override |
Public Member Functions inherited from helics::BaseTimeCoordinator | |
BaseTimeCoordinator (std::function< void(const ActionMessage &)> userSendMessageFunction) | |
void | setMessageSender (std::function< void(const ActionMessage &)> userSendMessageFunction) |
void | setRestrictivePolicy (bool policy) |
std::vector< GlobalFederateId > | getDependencies () const |
std::vector< GlobalFederateId > | getDependents () const |
Time | getLastGrant (GlobalFederateId fedId) const |
void | setSourceId (GlobalFederateId sourceId) |
GlobalFederateId | sourceId () const |
const DependencyInfo * | getDependencyInfo (GlobalFederateId ofed) const |
bool | isDependency (GlobalFederateId ofed) const |
bool | empty () const |
virtual TimeProcessingResult | processTimeMessage (const ActionMessage &cmd) |
void | processDependencyUpdateMessage (const ActionMessage &cmd) |
virtual bool | addDependency (GlobalFederateId fedID) |
virtual bool | addDependent (GlobalFederateId fedID) |
virtual void | removeDependency (GlobalFederateId fedID) |
virtual void | removeDependent (GlobalFederateId fedID) |
virtual void | resetDependency (GlobalFederateId fedID) |
void | setAsChild (GlobalFederateId fedID) |
void | setAsParent (GlobalFederateId fedID) |
void | setVersion (GlobalFederateId fedID, std::int8_t version) |
GlobalFederateId | getParent () const |
void | disconnect () |
virtual void | enteringExecMode (IterationRequest mode=IterationRequest::NO_ITERATIONS) |
bool | hasActiveTimeDependencies () const |
int | dependencyCount () const |
GlobalFederateId | getMinDependency () const |
Json::Value | grantTimeoutCheck (const ActionMessage &cmd) |
Protected Attributes | |
bool | iterating {false} |
flag indicating that the min dependency is iterating | |
Protected Attributes inherited from helics::BaseTimeCoordinator | |
TimeDependencies | dependencies |
std::function< void(const ActionMessage &)> | sendMessageFunction |
callback used to send the messages | |
GlobalFederateId | mSourceId {0} |
the identifier for inserting into the source id field of any generated messages; | |
std::int32_t | sequenceCounter {0} |
storage for sequence counter | |
bool | noParent {true} |
indicator that the coordinator does not have parents | |
bool | federatesOnly {false} |
indicator that the forwarder only operates with federates | |
bool | checkingExec {false} |
bool | executionMode {false} |
bool | restrictive_time_policy {false} |
flag indicating that a restrictive time policy should be used | |
bool | nonGranting {false} |
bool | delayedTiming {false} |
bool | disconnected {false} |
Additional Inherited Members | |
Static Public Attributes inherited from helics::BaseTimeCoordinator | |
static constexpr std::int32_t | TIME_COORDINATOR_VERSION {1} |
Protected Member Functions inherited from helics::BaseTimeCoordinator | |
ActionMessage | generateTimeRequest (const TimeData &dep, GlobalFederateId fed, std::int32_t responseCode) const |
void | sendTimingInfo () |
class implementing a time coordinator that explicitly allows asynchronous operation of the federates – that is, the federates are not time synchronized and are allowed to operate ahead of others. Potential uses are: 1) the use of an external time coordination mechanism, 2) a purely command driven system, 3) all federates are operated in real time mode, 4) you don't care about the data and just want to see how fast all the federates go on their own.
This time coordinator does only minimal time keeping for entry to execution mode and allows asynchronous operation of the federation
|
overridevirtual |
check if entry to the executing state can be granted
Implements helics::BaseTimeCoordinator.
References helics::CONTINUE_PROCESSING, helics::BaseTimeCoordinator::executionMode, helics::BaseTimeCoordinator::mSourceId, helics::NEXT_STEP, helics::ActionMessage::source_id, and helics::timeZero.
|
overridevirtual |
generate debugging time information
Reimplemented from helics::BaseTimeCoordinator.
References helics::BaseTimeCoordinator::generateDebuggingTimeInfo().
|
inlineoverridevirtual |
get the current next time
Implements helics::BaseTimeCoordinator.
|
overridevirtual |
generate a string with the current time status
Implements helics::BaseTimeCoordinator.
|
overridevirtual |
compute updates to time values and send an update if needed
Implements helics::BaseTimeCoordinator.
References helics::BaseTimeCoordinator::dependencies, and helics::BaseTimeCoordinator::mSourceId.