pub enum NetEvent {
PacketCreated(EventUTC, PacketID),
PacketConsumed(EventUTC, PacketID, PacketLocation),
PacketDestroyed(EventUTC, PacketID, PacketLocation),
EpochCreated(EventUTC, EpochID),
EpochStarted(EventUTC, EpochID),
EpochFinished(EventUTC, Epoch),
EpochCancelled(EventUTC, Epoch),
PacketMoved(EventUTC, PacketID, PacketLocation, PacketLocation, usize),
InputSalvoTriggered(EventUTC, EpochID, SalvoConditionName),
OutputSalvoTriggered(EventUTC, EpochID, SalvoConditionName),
PacketOrphaned(EventUTC, PacketID, EpochID, NodeName, PortName, SalvoConditionName),
}Expand description
An event that occurred during a network action.
Events provide a complete audit trail of all state changes in the network. Each event includes a timestamp and relevant identifiers. Events contain all information needed to undo the operation.
Variants§
PacketCreated(EventUTC, PacketID)
A new packet was created.
PacketConsumed(EventUTC, PacketID, PacketLocation)
A packet was consumed (normal removal from the network). Includes the packet’s location before consumption for undo support.
PacketDestroyed(EventUTC, PacketID, PacketLocation)
A packet was destroyed (abnormal removal, e.g., epoch cancellation). Includes the packet’s location before destruction for undo support.
EpochCreated(EventUTC, EpochID)
A new epoch was created (in Startable state).
EpochStarted(EventUTC, EpochID)
An epoch transitioned from Startable to Running.
EpochFinished(EventUTC, Epoch)
An epoch completed successfully. Includes the full epoch state for undo support.
EpochCancelled(EventUTC, Epoch)
An epoch was cancelled. Includes the full epoch state for undo support.
PacketMoved(EventUTC, PacketID, PacketLocation, PacketLocation, usize)
A packet moved from one location to another. Includes the index in the source location for perfect undo restoration. (timestamp, packet_id, from_location, to_location, from_index)
InputSalvoTriggered(EventUTC, EpochID, SalvoConditionName)
An input salvo condition was triggered, creating an epoch.
OutputSalvoTriggered(EventUTC, EpochID, SalvoConditionName)
An output salvo condition was triggered, sending packets.
PacketOrphaned(EventUTC, PacketID, EpochID, NodeName, PortName, SalvoConditionName)
A packet was sent to an unconnected output port and moved to OutsideNet. (timestamp, packet_id, epoch_id, node_name, port_name, salvo_condition)