Class ProtobufMessageBodyConsumer
java.lang.Object
org.apache.hadoop.hbase.rest.provider.consumer.ProtobufMessageBodyConsumer
- All Implemented Interfaces:
org.apache.hbase.thirdparty.javax.ws.rs.ext.MessageBodyReader<ProtobufMessageHandler>
@Provider
@Consumes({"application/x-protobuf","application/protobuf"})
@Private
public class ProtobufMessageBodyConsumer
extends Object
implements org.apache.hbase.thirdparty.javax.ws.rs.ext.MessageBodyReader<ProtobufMessageHandler>
Adapter for hooking up Jersey content processing dispatch to ProtobufMessageHandler interface
capable handlers for decoding protobuf input.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isReadable
(Class<?> type, Type genericType, Annotation[] annotations, org.apache.hbase.thirdparty.javax.ws.rs.core.MediaType mediaType) readFrom
(Class<ProtobufMessageHandler> type, Type genericType, Annotation[] annotations, org.apache.hbase.thirdparty.javax.ws.rs.core.MediaType mediaType, org.apache.hbase.thirdparty.javax.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream inputStream)
-
Field Details
-
LOG
-
-
Constructor Details
-
ProtobufMessageBodyConsumer
public ProtobufMessageBodyConsumer()
-
-
Method Details
-
isReadable
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, org.apache.hbase.thirdparty.javax.ws.rs.core.MediaType mediaType) - Specified by:
isReadable
in interfaceorg.apache.hbase.thirdparty.javax.ws.rs.ext.MessageBodyReader<ProtobufMessageHandler>
-
readFrom
public ProtobufMessageHandler readFrom(Class<ProtobufMessageHandler> type, Type genericType, Annotation[] annotations, org.apache.hbase.thirdparty.javax.ws.rs.core.MediaType mediaType, org.apache.hbase.thirdparty.javax.ws.rs.core.MultivaluedMap<String, String> httpHeaders, InputStream inputStream) throws IOException, org.apache.hbase.thirdparty.javax.ws.rs.WebApplicationException- Specified by:
readFrom
in interfaceorg.apache.hbase.thirdparty.javax.ws.rs.ext.MessageBodyReader<ProtobufMessageHandler>
- Throws:
IOException
org.apache.hbase.thirdparty.javax.ws.rs.WebApplicationException
-