reply_error


Description:

public void reply_error (Request request, int error_code, Error? e = null)

Reply with a JSON-RPC error.

OLLMrpc.Error.code is error_code. When e is passed, message, domain, and OLLMrpc.Error.gerror_code are copied from it. Otherwise OLLMrpc.RpcErrorCode.to_response is used.

Parameters:

request

the request being answered

error_code

JSON-RPC number (OLLMrpc.RpcErrorCode)

e

thrown GLib.Error to send, or null for a protocol error