Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
erlingrj committed Dec 14, 2024
1 parent 11487af commit 088383a
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 16 deletions.
20 changes: 10 additions & 10 deletions include/reactor-uc/action.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,20 +14,20 @@ typedef enum { LOGICAL_ACTION, PHYSICAL_ACTION } ActionType;
struct Action {
Trigger super;
ActionType type;
interval_t min_offset; // The minimum offset from the current time that an event can be scheduled on this action.
interval_t min_spacing; // The minimum spacing between two events scheduled on this action.
instant_t last_event_time; // Logical time of most recent event scheduled on this action.
void *value_ptr; // Pointer to the value associated with this action at the current logical tag.
TriggerEffects effects; // The reactions triggered by this Action.
TriggerSources sources; // The reactions that can write to this Action.
TriggerObservers observers; // The reactions that can observe this Action.
interval_t min_offset; // The minimum offset from the current time that an event can be scheduled on this action.
interval_t min_spacing; // The minimum spacing between two events scheduled on this action.
instant_t last_event_time; // Logical time of most recent event scheduled on this action.
void *value_ptr; // Pointer to the value associated with this action at the current logical tag.
TriggerEffects effects; // The reactions triggered by this Action.
TriggerSources sources; // The reactions that can write to this Action.
TriggerObservers observers; // The reactions that can observe this Action.
EventPayloadPool payload_pool; // Pool of memory for the data associated with the events scheduled on this action.
size_t max_pending_events; // The maximum number of events that can be scheduled on this action.
size_t events_scheduled; // The number of events currently scheduled on this action.
size_t max_pending_events; // The maximum number of events that can be scheduled on this action.
size_t events_scheduled; // The number of events currently scheduled on this action.

/**
* @brief Schedule an event on this action.
*
*
* @param self The action to schedule the event on.
* @param offset The tag of the scheduled event will be the current tag plus the min_offset plus this offset.
* @param value A pointer to the value which should be scheduled with the event.
Expand Down
2 changes: 1 addition & 1 deletion include/reactor-uc/environment.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ struct Environment {

/**
* @brief Request the termination of the program.
*
*
* The program will terminate at the earliest possible time, which is the current logical tag plus a microstep.
*/
void (*request_shutdown)(Environment *self);
Expand Down
11 changes: 6 additions & 5 deletions include/reactor-uc/federated.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,22 +87,23 @@ void FederatedOutputConnection_ctor(FederatedOutputConnection *self, Reactor *pa

/**
* @brief A single input connection coming from another federate.
*
*
* This connection has a single upstream output port in the other federate, but might be connected to multiple input
* ports in the current federate.
*
* ports in the current federate.
*
*/
struct FederatedInputConnection {
Connection super;
interval_t delay; // The logical delay of this connection
ConnectionType type;
tag_t last_known_tag; // The latest tag this input is known at.
instant_t safe_to_assume_absent; // At physical time T it is safe to assume that this input port is absent at T - STAA.
instant_t
safe_to_assume_absent; // At physical time T it is safe to assume that this input port is absent at T - STAA.
EventPayloadPool payload_pool;
int conn_id;
/**
* @brief Schedule a received message on this input connection
*
*
* This is called by the network channel when a message is received.
*/
void (*schedule)(FederatedInputConnection *self, TaggedMessage *msg);
Expand Down

0 comments on commit 088383a

Please sign in to comment.