pub trait Request: Sized + __Classify {
type Payload;
// Required methods
fn payload(&self) -> &Self::Payload;
fn into_payload(self) -> Self::Payload;
fn from_payload(payload: Self::Payload) -> Self;
// Provided method
fn then<J, U>(self, jig: J) -> U
where J: Jig<Self, Out = U> { ... }
}Expand description
An inbound message flowing through a pipeline.
Types implementing this trait can be chained with .then(jig) on the
request side.
Required Associated Types§
Required Methods§
Sourcefn into_payload(self) -> Self::Payload
fn into_payload(self) -> Self::Payload
Consume the request and return the payload.
Sourcefn from_payload(payload: Self::Payload) -> Self
fn from_payload(payload: Self::Payload) -> Self
Wrap a payload into a request.
Provided 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.