public static class GzipFilter.GzipStream extends ServletOutputStream
Modifier and Type | Field and Description |
---|---|
protected ByteArrayOutputStream2 |
_bOut |
protected int |
_bufferSize |
protected boolean |
_closed |
protected long |
_contentLength |
protected java.util.zip.GZIPOutputStream |
_gzOut |
protected int |
_minGzipSize |
protected java.io.OutputStream |
_out |
protected HttpServletRequest |
_request |
protected HttpServletResponse |
_response |
Constructor and Description |
---|
GzipFilter.GzipStream(HttpServletRequest request,
HttpServletResponse response,
long contentLength,
int bufferSize,
int minGzipSize) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
doGzip() |
void |
doNotGzip() |
void |
finish() |
void |
flush() |
void |
resetBuffer() |
protected boolean |
setContentEncodingGzip() |
void |
setContentLength(long length) |
void |
write(byte[] b) |
void |
write(byte[] b,
int off,
int len) |
void |
write(int b) |
protected HttpServletRequest _request
protected HttpServletResponse _response
protected java.io.OutputStream _out
protected ByteArrayOutputStream2 _bOut
protected java.util.zip.GZIPOutputStream _gzOut
protected boolean _closed
protected int _bufferSize
protected int _minGzipSize
protected long _contentLength
public GzipFilter.GzipStream(HttpServletRequest request, HttpServletResponse response, long contentLength, int bufferSize, int minGzipSize) throws java.io.IOException
java.io.IOException
public void resetBuffer()
public void setContentLength(long length)
public void flush() throws java.io.IOException
flush
in interface java.io.Flushable
flush
in class java.io.OutputStream
java.io.IOException
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.OutputStream
java.io.IOException
public void finish() throws java.io.IOException
java.io.IOException
public void write(int b) throws java.io.IOException
write
in class java.io.OutputStream
java.io.IOException
public void write(byte[] b) throws java.io.IOException
write
in class java.io.OutputStream
java.io.IOException
public void write(byte[] b, int off, int len) throws java.io.IOException
write
in class java.io.OutputStream
java.io.IOException
protected boolean setContentEncodingGzip()
public void doGzip() throws java.io.IOException
java.io.IOException
public void doNotGzip() throws java.io.IOException
java.io.IOException
Copyright © 2009 Mortbay Consulting Pty. Ltd. All Rights Reserved.