encode

abstract fun encode(payload: Slice): CompletableFuture<Slice>

Encodes the given payload. This is applied after serialization.

Return

a future completed with the encoded payload

Parameters

payload

the payload to encode. Empty slices must be handled as well.