@Override
  public ProtobufMessageHandler readFrom(Class<ProtobufMessageHandler> type, Type genericType,
    Annotation[] annotations, MediaType mediaType, MultivaluedMap<String, String> httpHeaders,
    InputStream inputStream) throws IOException, WebApplicationException {
    ProtobufMessageHandler obj = null;
    try {
      obj = type.getDeclaredConstructor().newInstance();
      return obj.getObjectFromMessage(inputStream);
    } catch (InstantiationException | NoSuchMethodException | InvocationTargetException
      | IllegalAccessException e) {
      throw new WebApplicationException(e);
    }
  }
Adapter for hooking up Jersey content processing dispatch to ProtobufMessageHandler interface
capable handlers for decoding protobuf input.
hbase-rest/src/main/java/org/apache/hadoop/hbase/rest/provider/consumer/ProtobufMessageBodyConsumer.java