Struct salvo::http::headers::SecWebsocketAccept [−][src]
pub struct SecWebsocketAccept(_);
Expand description
The Sec-Websocket-Accept
header.
This header is used in the Websocket handshake, sent back by the
server indicating a successful handshake. It is a signature
of the Sec-Websocket-Key
header.
Example
use headers::{SecWebsocketAccept, SecWebsocketKey};
let sec_key: SecWebsocketKey = /* from request headers */
let sec_accept = SecWebsocketAccept::from(sec_key);
Trait Implementations
Performs the conversion.
The name of this header.
pub fn decode<'i, I>(values: &mut I) -> Result<SecWebsocketAccept, Error> where
I: Iterator<Item = &'i HeaderValue>,
pub fn decode<'i, I>(values: &mut I) -> Result<SecWebsocketAccept, Error> where
I: Iterator<Item = &'i HeaderValue>,
Decode this type from an iterator of HeaderValue
s.
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for SecWebsocketAccept
impl Send for SecWebsocketAccept
impl Sync for SecWebsocketAccept
impl Unpin for SecWebsocketAccept
impl UnwindSafe for SecWebsocketAccept
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key
and return true
if they are equal.
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Output = T
type Output = T
Should always be Self