public class EchoHandler extends Object implements RequestHandler
Constructor and Description |
---|
EchoHandler(JSONRPC2Helper helper) |
Modifier and Type | Method and Description |
---|---|
String[] |
handledRequests()
Gets the names of the handled JSON-RPC 2.0 request methods.
|
JSONRPC2Response |
process(JSONRPC2Request req,
MessageContext ctx)
Processes a JSON-RPC 2.0 request.
|
public EchoHandler(JSONRPC2Helper helper)
public String[] handledRequests()
RequestHandler
handledRequests
in interface RequestHandler
public JSONRPC2Response process(JSONRPC2Request req, MessageContext ctx)
RequestHandler
process
in interface RequestHandler
req
- A valid JSON-RPC 2.0 request instance. Must not be
null
.ctx
- Context information about the request message, may
be null
if undefined.