class DefaultWireConnection : WireConnection
(source)
A stateful connection between two peers under the Devp2p wire protocol.
<init> |
Default constructor. DefaultWireConnection(id: String!, nodeId: Bytes!, peerNodeId: Bytes!, writer: Consumer<RLPxMessage!>!, afterHandshakeListener: Consumer<HelloMessage!>!, disconnectHandler: Runnable!, subprotocols: LinkedHashMap<SubProtocol!, SubProtocolHandler!>!, p2pVersion: Int, clientId: String!, advertisedPort: Int, ready: CompletableAsyncResult<String!>!) |
disconnect |
Sends a message to the peer explaining that we are about to disconnect. fun disconnect(reason: DisconnectReason!): Unit |
handleConnectionStart |
fun handleConnectionStart(): Unit |
id |
fun id(): String! |
messageReceived |
fun messageReceived(message: RLPxMessage!): Unit |
sendMessage |
fun sendMessage(subProtocolIdentifier: SubProtocolIdentifier!, messageType: Int, message: Bytes!): Unit |
sendPing |
Sends a ping message to the remote peer. fun sendPing(): AsyncCompletion! |
supports |
fun supports(subProtocolIdentifier: SubProtocolIdentifier!): Boolean |
toString |
fun toString(): String |