Struct tokio_jsonrpc::server::Empty
[−]
[src]
pub struct Empty;
A RPC server that knows no methods.
You can use this if you want to have a client-only
Endpoint. It simply terminates the server part right away.
Or, more conveniently, use Endpoint
's
client_only
method.
Trait Implementations
impl Server for Empty
[src]
type Success = ()
The successfull result of the RPC call.
type RpcCallResult = Result<(), RpcError>
The result of the RPC call Read more
type NotificationResult = Result<(), ()>
The result of the RPC call. Read more
fn initialized(&self, ctl: &ServerCtl)
Called when the endpoint is initialized. Read more
fn rpc(
&self,
_ctl: &ServerCtl,
_method: &str,
_params: &Option<Value>
) -> Option<Self::RpcCallResult>
&self,
_ctl: &ServerCtl,
_method: &str,
_params: &Option<Value>
) -> Option<Self::RpcCallResult>
Called when the client requests something. Read more
fn notification(
&self,
_ctl: &ServerCtl,
_method: &str,
_params: &Option<Value>
) -> Option<Self::NotificationResult>
&self,
_ctl: &ServerCtl,
_method: &str,
_params: &Option<Value>
) -> Option<Self::NotificationResult>
Called when the client sends a notification. Read more