Struct twist_lz4::ServerLz4 [] [src]

pub struct ServerLz4 { /* fields omitted */ }

The lz4 server-side extension configuration.

Methods

impl Lz4
[src]

Add a stdout slog Logger to this protocol.

Add a stderr slog Logger to this protocol.

Trait Implementations

impl Default for Lz4
[src]

Returns the "default value" for a type. Read more

impl Header for Lz4
[src]

Initialize your extension from the given Sec-WebSocket-Extensions header string. If your extension parameters exist, but are invalid, you should return an error here. If they don't exist you should mark yourself disabled (see enabled below), and return Ok. For a server-side extension, this will be called first, and should be used to generate the value that will be returned by into_header. For a client-side extension, this will be called after the server response is received, and should be use to re-configure your extension based on the value. Read more

This should return your extensions Sec-WebSocket-Extensions header to be used in a request or response. For a server-side extension, this will be called after from_header has been called and the extension is configures. This result should represent your negotiation response. For a client-side extension, this will be called to ge the header for an extension negotiation request. Read more

impl PerMessage for Lz4
[src]

Is this extension enabled? This should return true if you are able to support the given Sec-WebSocket-Extensions header parameters. It should return false otherwise. Read more

Reserve rsvX bits for use by your extension. Valid values are 0 - 8 (no rsv bits reserved, up to all 3). If your bits are already reserved by an extension earlier in the chain, return an io::Error. Read more

Transform the given application data/extension data bytes as necessary.

Transform the given bytes into application/extension data bytes as necessary.