Trait socketioxide::handler::message::FromMessage
source · pub trait FromMessage<A: Adapter, M = ViaRequest>: Sized {
type Error: Error + 'static;
// Required method
fn from_message(
s: Arc<Socket<A>>,
v: Value,
p: Vec<Vec<u8>>,
ack_id: Option<i64>
) -> Result<Self, Self::Error>;
}
Expand description
A trait used to extract and consume arguments from the message event.
The Result
associated type is used to return an error if the extraction fails, in this case the handler is not called.
Required Associated Types§
Required Methods§
Object Safety§
This trait is not object safe.