pub trait AsyncRpcHandler: Send + Sync {
// Required method
fn handle(
&self,
raw_data: &str,
) -> Pin<Box<dyn Future<Output = Result<Box<dyn ToRPCType>>> + Send>>;
}Expand description
The type-erased async handler trait
Required Methods§
fn handle( &self, raw_data: &str, ) -> Pin<Box<dyn Future<Output = Result<Box<dyn ToRPCType>>> + Send>>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".