public class IdentityOutputFilter extends java.lang.Object implements OutputFilter
Modifier and Type | Field and Description |
---|---|
protected OutputBuffer |
buffer
Next buffer in the pipeline.
|
protected long |
contentLength
Content length.
|
protected long |
remaining
Remaining bytes.
|
Constructor and Description |
---|
IdentityOutputFilter() |
Modifier and Type | Method and Description |
---|---|
int |
doWrite(ByteChunk chunk,
Response res)
Write some bytes.
|
long |
end()
End the current request.
|
long |
getBytesWritten()
Bytes written to the underlying socket.
|
void |
recycle()
Make the filter ready to process the next request.
|
void |
setBuffer(OutputBuffer buffer)
Set the next buffer in the filter pipeline.
|
void |
setResponse(Response response)
Some filters need additional parameters from the response.
|
protected long contentLength
protected long remaining
protected OutputBuffer buffer
public int doWrite(ByteChunk chunk, Response res) throws java.io.IOException
doWrite
in interface OutputFilter
doWrite
in interface OutputBuffer
chunk
- data to writeres
- used to allow buffers that can be shared by multiple
responses.java.io.IOException
public long getBytesWritten()
OutputBuffer
getBytesWritten
in interface OutputBuffer
public void setResponse(Response response)
setResponse
in interface OutputFilter
public void setBuffer(OutputBuffer buffer)
setBuffer
in interface OutputFilter
public long end() throws java.io.IOException
end
in interface OutputFilter
java.io.IOException
public void recycle()
recycle
in interface OutputFilter
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.