#[non_exhaustive]pub enum ServerCodec {
Uncompressed,
Zstd,
Brotli,
Gzip,
}Expand description
Codec for servers providing the Titan WebSocket API version 1.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Uncompressed
V1 messages encoded via MessagePack with no compression.
Zstd
V1 messages encoded via MessagePack with zstd compression.
Brotli
V1 messages encoded via MessagePack with brotli compression.
Gzip
V1 messages encoded via MessagePack with gzip compression.
Trait Implementations§
Source§impl Codec for ServerCodec
impl Codec for ServerCodec
Source§type SendItem = ServerMessage
type SendItem = ServerMessage
The type of message that is sent to the other side.
Source§type SendError = EncodeError
type SendError = EncodeError
The type of error that is returned if encoding fails.
Source§type RecvItem = ClientRequest
type RecvItem = ClientRequest
The type of message that is expected to be received from the other side.
Source§type RecvError = DecodeError
type RecvError = DecodeError
The type of error that is returned if decoding fails.
Source§impl Debug for ServerCodec
impl Debug for ServerCodec
Source§impl Default for ServerCodec
impl Default for ServerCodec
Source§fn default() -> ServerCodec
fn default() -> ServerCodec
Returns the “default value” for a type. Read more
Source§impl FromStr for ServerCodec
impl FromStr for ServerCodec
Source§impl PartialEq for ServerCodec
impl PartialEq for ServerCodec
impl Eq for ServerCodec
impl StructuralPartialEq for ServerCodec
Auto Trait Implementations§
impl Freeze for ServerCodec
impl RefUnwindSafe for ServerCodec
impl Send for ServerCodec
impl Sync for ServerCodec
impl Unpin for ServerCodec
impl UnsafeUnpin for ServerCodec
impl UnwindSafe for ServerCodec
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