public interface ResponseWriter<T>
Modifier and Type | Method and Description |
---|---|
MediaType |
getContentType()
Get the current contentType
|
MediaType |
getEncodedContentType(ResponseFormat responseFormat) |
void |
setContentType(MediaType contentType)
Set the contentType
|
boolean |
supportsGZip(T t)
Check if GZip is supported by this writer
|
void |
write(T t,
OutputStream out,
ResponseProxy responseProxy)
Write object t to
OutputStream out |
MediaType getContentType()
void setContentType(MediaType contentType)
contentType
- to setMediaType getEncodedContentType(ResponseFormat responseFormat)
void write(T t, OutputStream out, ResponseProxy responseProxy) throws IOException
OutputStream
outt
- Object to writeout
- OutputStream
to be written toresponseProxy
- ResponseProxy
giving access to header and content length settersIOException
- If an error occurs during writingboolean supportsGZip(T t)
t
- Object to writetrue
, if GZip is supportedCopyright © 2012-2014 52north.org. All Rights Reserved.