Trait crux_core::capability::Operation
source · pub trait Operation: Serialize + PartialEq + Send + 'static {
type Output: DeserializeOwned + Send + 'static;
}
Expand description
Operation trait links together input and output of a side-effect.
You implement Operation
on the payload sent by the capability to the shell using CapabilityContext::request_from_shell
.
For example (from crux_http
):
ⓘ
impl Operation for HttpRequest {
type Output = HttpResponse;
}
Required Associated Types§
sourcetype Output: DeserializeOwned + Send + 'static
type Output: DeserializeOwned + Send + 'static
Output
assigns the type this request results in.
Object Safety§
This trait is not object safe.