@Provider public class DataSourceProvider<T> extends Object implements javax.ws.rs.ext.MessageBodyReader<T>, javax.ws.rs.ext.MessageBodyWriter<T>
Constructor and Description |
---|
DataSourceProvider() |
Modifier and Type | Method and Description |
---|---|
long |
getSize(T t,
Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mt) |
boolean |
isReadable(Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mt) |
boolean |
isWriteable(Class<?> type,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType mt) |
T |
readFrom(Class<T> cls,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType type,
javax.ws.rs.core.MultivaluedMap<String,String> headers,
InputStream is) |
void |
setUseDataSourceContentType(boolean useDataSourceContentType) |
void |
writeTo(T src,
Class<?> cls,
Type genericType,
Annotation[] annotations,
javax.ws.rs.core.MediaType type,
javax.ws.rs.core.MultivaluedMap<String,Object> headers,
OutputStream os) |
protected static final Logger LOG
public boolean isReadable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mt)
isReadable
in interface javax.ws.rs.ext.MessageBodyReader<T>
public T readFrom(Class<T> cls, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType type, javax.ws.rs.core.MultivaluedMap<String,String> headers, InputStream is) throws IOException
readFrom
in interface javax.ws.rs.ext.MessageBodyReader<T>
IOException
public long getSize(T t, Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mt)
getSize
in interface javax.ws.rs.ext.MessageBodyWriter<T>
public boolean isWriteable(Class<?> type, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType mt)
isWriteable
in interface javax.ws.rs.ext.MessageBodyWriter<T>
public void writeTo(T src, Class<?> cls, Type genericType, Annotation[] annotations, javax.ws.rs.core.MediaType type, javax.ws.rs.core.MultivaluedMap<String,Object> headers, OutputStream os) throws IOException
writeTo
in interface javax.ws.rs.ext.MessageBodyWriter<T>
IOException
public void setUseDataSourceContentType(boolean useDataSourceContentType)
Apache CXF