Type Alias jsonrpsee::SyncMethod

source ·
pub type SyncMethod = Arc<dyn Fn(Id<'_>, Params<'_>, usize, Extensions) -> MethodResponse + Send + Sync>;
Expand description

A MethodCallback is an RPC endpoint, callable with a standard JSON-RPC request, implemented as a function pointer to a Fn function taking four arguments: the id, params, a channel the function uses to communicate the result (or error) back to jsonrpsee, and the connection ID (useful for the websocket transport).

Aliased Type§

struct SyncMethod { /* private fields */ }