Skip to main content

antenna_protocol/handshake/
state.rs

1/// Handshake-level state of the client handshake FSM.
2#[derive(Debug, PartialEq, Eq, Clone)]
3pub enum HandshakeState {
4    /// Peer created but negotiation hasn't started yet
5    Idle,
6
7    /// Host is creating offer
8    CreatingOffer,
9
10    /// Host sent offer to joiner and is waiting for other peer answer
11    WaitingForAnswer,
12
13    /// Joiner is creating answer
14    CreatingAnswer,
15
16    /// Joiner sent answer and waiting to establish data channel with host
17    WaitingForDataChannel,
18
19    /// Peer has established connection with other peer
20    Connected,
21
22    /// Connection is closed
23    Closed,
24}