pub enum Frame {
Hello {
node: String,
credential: Option<String>,
hosts: Vec<String>,
},
Welcome {
node: String,
hosts: Vec<String>,
},
Refused {
reason: String,
},
Message(Message),
Ack {
id: String,
},
}Expand description
One frame of the protocol.
Variants§
Hello
The client’s first frame.
Fields
Welcome
The server accepted the connection.
Fields
Refused
The server refused the credential and closes the connection.
Message(Message)
A message.
Ack
The receiver accepted message id.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Frame
impl<'de> Deserialize<'de> for Frame
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Frame
Auto Trait Implementations§
impl Forget for Frame
impl Freeze for Frame
impl Move for Frame
impl RefUnwindSafe for Frame
impl Send for Frame
impl Sync for Frame
impl Unpin for Frame
impl UnsafeUnpin for Frame
impl UnwindSafe for Frame
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