tuweni / org.apache.tuweni.scuttlebutt.rpc.mux / RPCHandler

RPCHandler

open class RPCHandler : Multiplexer, ClientHandler (source)

Handles RPC requests and responses from an active connection to a scuttlebutt node.

Constructors

<init>

Makes RPC requests over a connection

RPCHandler(vertx: Vertx!, messageSender: Consumer<Bytes!>!, terminationFn: Runnable!)

Functions

close

open fun close(): Unit

makeAsyncRequest

open fun makeAsyncRequest(request: RPCAsyncRequest!): AsyncResult<RPCResponse!>!

openStream

open fun openStream(request: RPCStreamRequest!, responseSink: Function<Runnable!, ScuttlebuttStreamHandler!>!): Unit

receivedMessage

open fun receivedMessage(message: Bytes!): Unit

streamClosed

open fun streamClosed(): Unit