pub enum ControlEvent {
OpenRequest {
request_id: u64,
service: ServiceId,
metadata: Metadata,
},
OpenResponseReceived {
request_id: u64,
accepted: bool,
},
CloseReceived {
code: CloseCode,
reason: Option<String>,
},
Ping {
sequence: u64,
},
Pong {
sequence: u64,
},
StreamClose {
logical_stream_id: u64,
code: CloseCode,
},
}Expand description
Events that can occur on the control stream.
Variants§
OpenRequest
Peer requested to open a stream.
Fields
OpenResponseReceived
Response to our open request was received.
Fields
CloseReceived
Peer initiated close.
Ping
Ping received (pong auto-sent).
Pong
Pong received in response to our ping.
StreamClose
Stream close notification.
Trait Implementations§
Source§impl Clone for ControlEvent
impl Clone for ControlEvent
Source§fn clone(&self) -> ControlEvent
fn clone(&self) -> ControlEvent
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ControlEvent
impl RefUnwindSafe for ControlEvent
impl Send for ControlEvent
impl Sync for ControlEvent
impl Unpin for ControlEvent
impl UnwindSafe for ControlEvent
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