pub trait RpcFunc<T>:
Send
+ Sync
+ 'static {
type Resp: Serialize + ToRPCType + 'static;
// Required method
fn call(&self, req: T) -> Result<Self::Resp>;
}Expand description
A trait that captures the relationship between a request type T and its response.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".