pub enum TcpEvent {
ConnectionEstablished {
from: NodeAddress,
to: NodeAddress,
},
ConnectionRefused {
from: NodeAddress,
to: NodeAddress,
},
ConnectionTimeout {
from: NodeAddress,
to: NodeAddress,
},
ConnectionReset {
from: NodeAddress,
to: NodeAddress,
},
ConnectionClosed {
from: NodeAddress,
to: NodeAddress,
},
}Expand description
Events the TcpSimBus delivers to nodes alongside messages.
Nodes train these via TcpSimBus::drain_events() after each tick.
Variants§
ConnectionEstablished
A connection request from from to to was accepted.
ConnectionRefused
A connection request was refused by the bus fault injector.
ConnectionTimeout
A connection request timed out
ConnectionReset
An established connection was reset by the bus fault injector. Both nodes should threat this as a TCP RST
ConnectionClosed
The connection was closed cleanly by one of the nodes.
Trait Implementations§
impl Eq for TcpEvent
impl StructuralPartialEq for TcpEvent
Auto Trait Implementations§
impl Freeze for TcpEvent
impl RefUnwindSafe for TcpEvent
impl Send for TcpEvent
impl Sync for TcpEvent
impl Unpin for TcpEvent
impl UnsafeUnpin for TcpEvent
impl UnwindSafe for TcpEvent
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more