@Provider @Produces(value="application/json") @Consumes(value="application/json") public class JsonbJaxrsProvider<T> extends Object implements javax.ws.rs.ext.MessageBodyWriter<T>, javax.ws.rs.ext.MessageBodyReader<T>
Modifier | Constructor and Description |
---|---|
|
JsonbJaxrsProvider() |
protected |
JsonbJaxrsProvider(Collection<String> ignores) |
Modifier and Type | Method and Description |
---|---|
protected Jsonb |
createJsonb() |
long |
getSize(T t,
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) |
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) |
void |
setBinaryDataStrategy(String binaryDataStrategy) |
void |
setEncoding(String encoding) |
void |
setIJson(boolean active) |
void |
setNullValues(boolean nulls) |
void |
setPretty(boolean pretty) |
void |
setPropertyNamingStrategy(String propertyNamingStrategy) |
void |
setPropertyOrderStrategy(String propertyOrderStrategy) |
void |
writeTo(T t,
Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mediaType,
javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders,
OutputStream entityStream) |
public JsonbJaxrsProvider()
protected JsonbJaxrsProvider(Collection<String> ignores)
protected Jsonb createJsonb()
public void setIJson(boolean active)
public void setEncoding(String encoding)
public void setBinaryDataStrategy(String binaryDataStrategy)
public void setPropertyNamingStrategy(String propertyNamingStrategy)
public void setPropertyOrderStrategy(String propertyOrderStrategy)
public void setNullValues(boolean nulls)
public void setPretty(boolean pretty)
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
isReadable
in interface javax.ws.rs.ext.MessageBodyReader<T>
public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
isWriteable
in interface javax.ws.rs.ext.MessageBodyWriter<T>
public long getSize(T t, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType)
getSize
in interface javax.ws.rs.ext.MessageBodyWriter<T>
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
readFrom
in interface javax.ws.rs.ext.MessageBodyReader<T>
IOException
javax.ws.rs.WebApplicationException
public void writeTo(T t, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mediaType, javax.ws.rs.core.MultivaluedMap<String,Object> httpHeaders, OutputStream entityStream) throws IOException, javax.ws.rs.WebApplicationException
writeTo
in interface javax.ws.rs.ext.MessageBodyWriter<T>
IOException
javax.ws.rs.WebApplicationException
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.