pub trait StreamParser<Output> {
type Stream: Stream;
type Message;
type Error;
// Required method
fn parse(
input: Result<Self::Message, Self::Error>,
) -> Option<Result<Output, SocketError>>;
}Expand description
StreamParsers are capable of parsing the input messages from a given stream protocol
(eg/ WebSocket, Financial Information eXchange (FIX), etc.) and deserialising into an Output.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.