| Modifier and Type | Field and Description |
|---|---|
protected Logger |
log |
protected com.fasterxml.jackson.databind.ObjectMapper |
objectMapper |
| Constructor and Description |
|---|
JsonMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper) |
| Modifier and Type | Method and Description |
|---|---|
protected com.fasterxml.jackson.core.JsonFactory |
getReaderJsonFactory() |
long |
getSize(Object value,
Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType) |
boolean |
isReadable(Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType) |
boolean |
isWriteable(Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType) |
Object |
readFrom(Class<Object> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType,
javax.ws.rs.core.MultivaluedMap<String,String> httpHeaders,
InputStream inputStream) |
void |
setUriInfo(javax.ws.rs.core.UriInfo uriInfo) |
protected void |
write(Object value,
Optional<com.fasterxml.jackson.databind.JavaType> rootType,
javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders,
OutputStream outputStream) |
void |
writeTo(Object value,
Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType,
javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders,
OutputStream outputStream) |
protected final Logger log
protected final com.fasterxml.jackson.databind.ObjectMapper objectMapper
@Inject public JsonMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
@Context public void setUriInfo(javax.ws.rs.core.UriInfo uriInfo)
protected com.fasterxml.jackson.core.JsonFactory getReaderJsonFactory()
protected void write(Object value, Optional<com.fasterxml.jackson.databind.JavaType> rootType, javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream outputStream) throws IOException
IOExceptionpublic boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
isReadable in interface javax.ws.rs.ext.MessageBodyReader<Object>public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
isWriteable in interface javax.ws.rs.ext.MessageBodyWriter<Object>public Object readFrom(Class<Object> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,String> httpHeaders, InputStream inputStream) throws IOException
readFrom in interface javax.ws.rs.ext.MessageBodyReader<Object>IOExceptionpublic long getSize(Object value, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
getSize in interface javax.ws.rs.ext.MessageBodyWriter<Object>public void writeTo(Object value, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream outputStream) throws IOException
writeTo in interface javax.ws.rs.ext.MessageBodyWriter<Object>IOExceptionCopyright © 2010–2020 Airlift. All rights reserved.