![]() |
reactor-c 1.0
C Runtime for Lingua Franca
|
Structure that a federate instance uses to keep track of its own state. More...
#include <federate.h>
Data Fields | |
| bool | has_downstream |
| Indicator of whether this federate has downstream federates. | |
| bool | has_upstream |
| Indicator of whether this federate has upstream federates. | |
| lf_thread_t * | inbound_net_listeners |
| Array of thread IDs for threads that listen for incoming messages. | |
| lf_thread_t | inbound_p2p_handling_thread_id |
| Thread ID for a thread that accepts network abstractions and then supervises listening to those network abstractions for incoming P2P (physical) connections. | |
| bool | is_last_TAG_provisional |
| Indicates whether the last TAG received is provisional or an ordinary TAG. | |
| tag_t | last_DNET |
| A record of the most recent DNET (downstream next event tag) signal. | |
| tag_t | last_sent_LTC |
| A record of the most recently sent LTC (latest tag confirmed) message. | |
| tag_t | last_sent_NET |
| A record of the most recently sent NET (next event tag) signal. | |
| tag_t | last_skipped_NET |
| A record of the most recently skipped NET (next event tag) signal. | |
| tag_t | last_TAG |
| Most recent tag advance grant (TAG) received from the RTI, or NEVER if none has been received. | |
| instant_t | min_delay_from_physical_action_to_federate_output |
| For use in federates with centralized coordination, the minimum time delay between a physical action within this federate and an output from this federate. | |
| net_abstraction_t | net_for_inbound_p2p_connections [NUMBER_OF_FEDERATES] |
| An array that holds the network abstractions for inbound connections from each federate. | |
| net_abstraction_t | net_for_outbound_p2p_connections [NUMBER_OF_FEDERATES] |
| An array that holds the network abstractions for outbound direct connections to each remote federate. | |
| net_abstraction_t | net_to_RTI |
| The network abstraction for this federate to communicate with the RTI. | |
| size_t | number_of_inbound_p2p_connections |
| Number of inbound physical connections to the federate. | |
| size_t | number_of_outbound_p2p_connections |
| Number of outbound peer-to-peer connections from the federate. | |
| bool | received_any_DNET |
| Indicator of whether this federate has received any DNET (downstream next event tag) signal. | |
| bool | received_stop_request_from_rti |
| Used to prevent the federate from sending a REQUEST_STOP message if it has already received a stop request from the RTI. | |
| lf_thread_t | RTI_net_listener |
| Thread listening for incoming messages from the RTI. | |
| net_abstraction_t | server_net |
| A network abstraction for the server of the federate. | |
| lf_thread_t | staaSetter |
| Thread responsible for setting ports to absent by an STAA offset if they aren't already known. | |
Structure that a federate instance uses to keep track of its own state.
| bool federate_instance_t::has_downstream |
Indicator of whether this federate has downstream federates.
The default value of false may be overridden in _lf_initialize_trigger_objects.
| bool federate_instance_t::has_upstream |
Indicator of whether this federate has upstream federates.
The default value of false may be overridden in _lf_initialize_trigger_objects.
| lf_thread_t* federate_instance_t::inbound_net_listeners |
Array of thread IDs for threads that listen for incoming messages.
This is NULL if there are none and otherwise has size given by number_of_inbound_p2p_connections.
| lf_thread_t federate_instance_t::inbound_p2p_handling_thread_id |
Thread ID for a thread that accepts network abstractions and then supervises listening to those network abstractions for incoming P2P (physical) connections.
| bool federate_instance_t::is_last_TAG_provisional |
Indicates whether the last TAG received is provisional or an ordinary TAG.
If the last TAG has been provisional, network port absent reactions must be inserted. This variable should only be accessed while holding the mutex lock.
| tag_t federate_instance_t::last_DNET |
A record of the most recent DNET (downstream next event tag) signal.
| tag_t federate_instance_t::last_sent_LTC |
A record of the most recently sent LTC (latest tag confirmed) message.
In some situations, federates can send logical_tag_complete for the same tag twice or more in-a-row to the RTI. For example, when _lf_next() returns without advancing tag. To prevent overwhelming the RTI with extra messages, record the last sent logical tag complete message and check against it in lf_latest_tag_confirmed().
| tag_t federate_instance_t::last_sent_NET |
A record of the most recently sent NET (next event tag) signal.
| tag_t federate_instance_t::last_skipped_NET |
A record of the most recently skipped NET (next event tag) signal.
| tag_t federate_instance_t::last_TAG |
Most recent tag advance grant (TAG) received from the RTI, or NEVER if none has been received.
This variable should only be accessed while holding the mutex lock on the top-level environment.
| instant_t federate_instance_t::min_delay_from_physical_action_to_federate_output |
For use in federates with centralized coordination, the minimum time delay between a physical action within this federate and an output from this federate.
This is NEVER if there is causal path from a physical action to any output.
| net_abstraction_t federate_instance_t::net_for_inbound_p2p_connections[NUMBER_OF_FEDERATES] |
An array that holds the network abstractions for inbound connections from each federate.
The index will be the federate ID of the remote sending federate. This is initialized at startup to NULL and is set to the pointer of the network abstraction by lf_connect_to_federate() when the network abstractions is opened.
| net_abstraction_t federate_instance_t::net_for_outbound_p2p_connections[NUMBER_OF_FEDERATES] |
An array that holds the network abstractions for outbound direct connections to each remote federate.
The index will be the federate ID of the remote receiving federate. This is initialized at startup to NULL and is set to the pointer of the network abstraction by lf_connect_to_federate() when the network abstractions is opened.
| net_abstraction_t federate_instance_t::net_to_RTI |
The network abstraction for this federate to communicate with the RTI.
This is set by lf_connect_to_rti(), which must be called before other functions that communicate with the rti are called.
| size_t federate_instance_t::number_of_inbound_p2p_connections |
Number of inbound physical connections to the federate.
This can be either physical connections, or logical connections in the decentralized coordination, or both.
| size_t federate_instance_t::number_of_outbound_p2p_connections |
Number of outbound peer-to-peer connections from the federate.
This can be either physical connections, or logical connections in the decentralized coordination, or both.
| bool federate_instance_t::received_any_DNET |
Indicator of whether this federate has received any DNET (downstream next event tag) signal.
| bool federate_instance_t::received_stop_request_from_rti |
Used to prevent the federate from sending a REQUEST_STOP message if it has already received a stop request from the RTI.
This variable should only be accessed while holding a mutex lock.
| lf_thread_t federate_instance_t::RTI_net_listener |
Thread listening for incoming messages from the RTI.
| net_abstraction_t federate_instance_t::server_net |
A network abstraction for the server of the federate.
This is assigned in lf_create_server(). This network abstraction is used to listen to incoming physical connections from remote federates. Once an incoming connection is accepted, the opened network abstraction will be stored in federate_net_for_inbound_p2p_connections.
| lf_thread_t federate_instance_t::staaSetter |
Thread responsible for setting ports to absent by an STAA offset if they aren't already known.