Class Scheduler#

Class Documentation#

class Scheduler#

The schedule class for the state propagator.

Public Functions

void registerTimedEvent(const kc::ks_ptr<TimedEvent> &timed_event, const km::Ktime &curr_time)#

Register a TimedEvent.

Parameters:
  • timed_event – - The TimedEvent to register.

  • curr_time – - The current time. Used for error checking.

void unregisterTimedEvent(std::string_view name, bool pre_hop, bool okay_not_exists = false)#

Unregister a TimedEvent.

Parameters:
  • name – - The name of the TimedEvent.

  • pre_hop – - Whether this is a pre_hop timed event or not.

  • okay_not_exists – - If true, then do not error out if a timed event by this name does not exist with the given pre_hop setting, otherwise, error our if the given event is not found.

bool hasRegisteredTimedEvent(std::string_view name, bool pre_hop) const#

Determine whether a TimedEvent with the given name exists.

Parameters:
  • name – - The name of the TimedEvent.

  • pre_hop – - Whether this is a pre_hop timed event or not.

Returns:

true if a TimedEvent with the given name and pre_hop setting exists, false otherwise.

void executePreHopEvents(const km::Ktime &t)#

Execute all the pre-hop events for the provided time.

Parameters:

t – - The time to execute all pre-hop events for.

void executePostHopEvents(const km::Ktime &t)#

Execute all the post-hop events for the provided time.

Parameters:

t – - The time to execute all post-hop events for.

km::Ktime getNextExplicitHopEndTime() const#

Get the next explicit hop end time.

Returns:

The next explicit hop end time.

std::string dumpString(std::string_view prefix) const#

Dump info about the Scheduler to a string.

Parameters:

prefix – - Prefix to prepend to each line of the dump string.

Returns:

A string with the dump info.