pub enum HandshakeRole {
ExpectClientHello,
ExpectServerHello,
Either,
}Expand description
Which handshake form the decoder should expect. ClientHello
begins with the 8-byte magic; ServerHello does not. The transport
knows its role; callers that don’t (e.g. protocol smoke tests)
can use Either.
Variants§
ExpectClientHello
This decoder is on the server side — the next kind-0 frame is a ClientHello.
ExpectServerHello
This decoder is on the client side — the next kind-0 frame is a ServerHello.
Either
Try ClientHello first (match magic); fall back to ServerHello.
Trait Implementations§
Source§impl Clone for HandshakeRole
impl Clone for HandshakeRole
Source§fn clone(&self) -> HandshakeRole
fn clone(&self) -> HandshakeRole
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 moreSource§impl Debug for HandshakeRole
impl Debug for HandshakeRole
Source§impl PartialEq for HandshakeRole
impl PartialEq for HandshakeRole
impl Copy for HandshakeRole
impl Eq for HandshakeRole
impl StructuralPartialEq for HandshakeRole
Auto Trait Implementations§
impl Freeze for HandshakeRole
impl RefUnwindSafe for HandshakeRole
impl Send for HandshakeRole
impl Sync for HandshakeRole
impl Unpin for HandshakeRole
impl UnsafeUnpin for HandshakeRole
impl UnwindSafe for HandshakeRole
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