static fun encodeRequest(body: String, vararg flags: RPCFlag): Bytes
(source)static fun encodeRequest(body: Bytes, vararg flags: RPCFlag): Bytes
(source)
Encode a message as a RPC request.
body
- the body to encode as a RPC request
flags
- the flags of the RPC request
Return
the message encoded as a RPC request
static fun encodeRequest(body: Bytes, requestNumber: Int, vararg flags: RPCFlag): Bytes
(source)
Encode a message as a RPC request.
body
- the body to encode as a RPC request
requestNumber
- the number of the request. Must be equal or greater than one.
flags
- the flags of the RPC request
Return
the message encoded as a RPC request
static fun encodeRequest(body: Bytes, requestNumber: Int, flags: Byte): Bytes
(source)
Encode a message as an RPC request.
body
- the body to encode as an RPC request
requestNumber
- the request number
flags
- the flags of the RPC request (already encoded.)
Return
the message encoded as an RPC request