module

JsonRpc::Handler

Handler used by Client to handle requests.

Instance methods

handle_rpc_call(client : JsonRpc::Client, request : JsonRpc::Request, raw : String)

Called when a request has been received. Implementations have to return what to respond, or can raise a LocalCallError which is automatically turned into an error response.

Raising any other error will be caught in Client#invoke_locally.

The default implementation always responds with an unknown method error.

Source