class TcpMessage implements EncodedMessage {

    private ByteBuf payload;


    @Override
    public String toString() {<FILL_FUNCTION_BODY>}
}

        StringBuilder builder = new StringBuilder();

        if (ByteBufUtil.isText(payload, StandardCharsets.UTF_8)) {
            builder.append(payloadAsString());
        } else {
            ByteBufUtil.appendPrettyHexDump(builder, payload);
        }

        return builder.toString();
    
<no_super_class>