tuweni / org.apache.tuweni.scuttlebutt.handshake.vertx / ClientHandlerFactory / createHandler

createHandler

abstract fun createHandler(sender: Consumer<Bytes!>!, terminationFunction: Runnable!): T (source)

Creates a new handler associated with a valid streaming connection.

Parameters

sender - Consumer<Bytes!>!: the function to send bytes to the server

terminationFunction - Runnable!: a function to terminate the stream properly

Return
T: the created ClientHandler