public class ServletOutputStreamImpl extends javax.servlet.ServletOutputStream implements BufferWritableOutputStream
AsyncContextImpl. At most one lister can be active at
one time, which simplifies the thread safety requirements.| Constructor and Description |
|---|
ServletOutputStreamImpl(long contentLength,
ServletRequestContext servletRequestContext)
Construct a new instance.
|
ServletOutputStreamImpl(Long contentLength,
ServletRequestContext servletRequestContext,
int bufferSize)
Construct a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
closeAsync()
Closes the channel, and flushes any data out using async IO
This is used in two situations, if an output stream is not closed when a
request is done, and when performing a close on a stream that is in async
mode
|
void |
flush() |
void |
flushInternal() |
boolean |
isClosed() |
boolean |
isReady() |
void |
resetBuffer() |
void |
setBufferSize(int size) |
void |
setWriteListener(javax.servlet.WriteListener writeListener) |
void |
transferFrom(FileChannel source) |
void |
write(byte[] b) |
void |
write(byte[] b,
int off,
int len) |
void |
write(ByteBuffer byteBuffer) |
void |
write(ByteBuffer[] buffers) |
void |
write(int b) |
public ServletOutputStreamImpl(long contentLength,
ServletRequestContext servletRequestContext)
public ServletOutputStreamImpl(Long contentLength, ServletRequestContext servletRequestContext, int bufferSize)
public void write(int b)
throws IOException
write in class OutputStreamIOExceptionpublic void write(byte[] b)
throws IOException
write in class OutputStreamIOExceptionpublic void write(byte[] b,
int off,
int len)
throws IOException
write in class OutputStreamIOExceptionpublic void write(ByteBuffer[] buffers) throws IOException
write in interface BufferWritableOutputStreamIOExceptionpublic void write(ByteBuffer byteBuffer) throws IOException
write in interface BufferWritableOutputStreamIOExceptionpublic void flush()
throws IOException
flush in interface Flushableflush in class OutputStreamIOExceptionpublic void flushInternal()
throws IOException
IOExceptionpublic void transferFrom(FileChannel source) throws IOException
transferFrom in interface BufferWritableOutputStreamIOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class OutputStreamIOExceptionpublic void closeAsync()
throws IOException
IOExceptionpublic void resetBuffer()
public void setBufferSize(int size)
public boolean isClosed()
public boolean isReady()
isReady in class javax.servlet.ServletOutputStreampublic void setWriteListener(javax.servlet.WriteListener writeListener)
setWriteListener in class javax.servlet.ServletOutputStreamCopyright © 2013 JBoss by Red Hat. All Rights Reserved.