pub trait MessageProcessor:
Send
+ Sync
+ 'static {
type Output: Send + Clone + Sync + 'static + Debug;
// Required method
fn process_message(
&mut self,
message: ResponseMessage,
) -> Option<Self::Output>;
}Expand description
Trait for processing incoming Betfair streaming ResponseMessage objects into user-defined outputs.
Implementers can filter or transform messages and control which messages are forwarded to the client sink.
Required Associated Types§
Required Methods§
Sourcefn process_message(&mut self, message: ResponseMessage) -> Option<Self::Output>
fn process_message(&mut self, message: ResponseMessage) -> Option<Self::Output>
Process an incoming ResponseMessage.
Returns Some(Output) to forward a processed message, or None to drop it.