Class GsonReader<T>
java.lang.Object
one.microstream.storage.restclient.jersey.GsonReader<T>
- All Implemented Interfaces:
javax.ws.rs.ext.MessageBodyReader<T>
@Provider @Consumes("application/json") public class GsonReader<T> extends Object implements javax.ws.rs.ext.MessageBodyReader<T>
-
Constructor Summary
Constructors Constructor Description GsonReader()
-
Method Summary
Modifier and Type Method Description boolean
isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
T
readFrom(Class<T> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,String> httpHeaders, InputStream entityStream)
-
Constructor Details
-
GsonReader
public GsonReader()
-
-
Method Details
-
isReadable
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)- Specified by:
isReadable
in interfacejavax.ws.rs.ext.MessageBodyReader<T>
-
readFrom
public T readFrom(Class<T> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,String> httpHeaders, InputStream entityStream) throws IOException, javax.ws.rs.WebApplicationException- Specified by:
readFrom
in interfacejavax.ws.rs.ext.MessageBodyReader<T>
- Throws:
IOException
javax.ws.rs.WebApplicationException
-