pub fn header<K, V>(self, key: K, value: V) -> Self
    where
        HeaderName: TryFrom<K>,
        HeaderValue: TryFrom<V>,
    {
        WsBuilder {
            req: self.req.header(key, value),
        }
    }
/// Set a header for this request.
///
/// # Example
///
/// ```
/// let req = warp::test::ws()
///     .header("foo", "bar");
/// ```
///
/// # Panic
///
/// This panics if the passed strings are not able to be parsed as a valid
/// `HeaderName` and `HeaderValue`.
Set a header for this request.
Set a header for this request .
pub fn header<K, V>(self, key: K, value: V) -> Self
    where
        HeaderName: TryFrom<K>,
        HeaderValue: TryFrom<V>,
    {
        WsBuilder {
            req: self.req.header(key, value),
        }
    }
pub fn header < K , V > ( self , key : K , value : V ) -> Self where HeaderName : TryFrom < K > , HeaderValue : TryFrom < V > , { WsBuilder { req : self . req . header ( key , value ) , } }
Set a header for this request.
Set a header for this request .
self
key
K
value
V
example
None
panic
This panics if the passed strings are not able to be parsed as a valid
`HeaderName` and `HeaderValue`.
This panics if the passed strings are not able to be parsed as a valid ` HeaderName ` and ` HeaderValue ` .