@Override
protected JsonDocument doDecode(String id, ByteBuf content, long cas, int expiry, int flags, ResponseStatus status)
throws Exception {
if (!TranscoderUtils.hasJsonFlags(flags)) {
throw new TranscodingException("Flags (0x" + Integer.toHexString(flags) + ") indicate non-JSON document for "
+ "id " + id + ", could not decode.");
}
JsonObject converted = stringToJsonObject(content.toString(CharsetUtil.UTF_8));
return newDocument(id, expiry, converted, cas);