class MySQLJsonValueDecoder {

    public static Serializable decode(final ByteBuf byteBuf) {
        int valueType = byteBuf.readUnsignedByte() & 0xff;
        StringBuilder result = new StringBuilder();
        decodeValue(valueType, 1, byteBuf, result);
        return result.toString();
    }

}