HttpOutput.Interceptor
public class GzipHttpOutputInterceptor extends java.lang.Object implements HttpOutput.Interceptor
Modifier and Type | Field | Description |
---|---|---|
static org.eclipse.jetty.util.log.Logger |
LOG |
|
static org.eclipse.jetty.http.HttpField |
VARY_ACCEPT_ENCODING |
|
static org.eclipse.jetty.http.HttpField |
VARY_ACCEPT_ENCODING_USER_AGENT |
Constructor | Description |
---|---|
GzipHttpOutputInterceptor(GzipFactory factory,
org.eclipse.jetty.http.HttpField vary,
int bufferSize,
HttpChannel channel,
HttpOutput.Interceptor next,
boolean syncFlush) |
|
GzipHttpOutputInterceptor(GzipFactory factory,
org.eclipse.jetty.http.HttpField vary,
HttpChannel channel,
HttpOutput.Interceptor next,
boolean syncFlush) |
|
GzipHttpOutputInterceptor(GzipFactory factory,
HttpChannel channel,
HttpOutput.Interceptor next,
boolean syncFlush) |
Modifier and Type | Method | Description |
---|---|---|
protected void |
commit(java.nio.ByteBuffer content,
boolean complete,
org.eclipse.jetty.util.Callback callback) |
|
HttpOutput.Interceptor |
getNextInterceptor() |
|
boolean |
isOptimizedForDirectBuffers() |
|
boolean |
mightCompress() |
|
void |
noCompression() |
|
void |
noCompressionIfPossible() |
|
void |
write(java.nio.ByteBuffer content,
boolean complete,
org.eclipse.jetty.util.Callback callback) |
Write content.
|
resetBuffer
public static org.eclipse.jetty.util.log.Logger LOG
public static final org.eclipse.jetty.http.HttpField VARY_ACCEPT_ENCODING_USER_AGENT
public static final org.eclipse.jetty.http.HttpField VARY_ACCEPT_ENCODING
public GzipHttpOutputInterceptor(GzipFactory factory, HttpChannel channel, HttpOutput.Interceptor next, boolean syncFlush)
public GzipHttpOutputInterceptor(GzipFactory factory, org.eclipse.jetty.http.HttpField vary, HttpChannel channel, HttpOutput.Interceptor next, boolean syncFlush)
public GzipHttpOutputInterceptor(GzipFactory factory, org.eclipse.jetty.http.HttpField vary, int bufferSize, HttpChannel channel, HttpOutput.Interceptor next, boolean syncFlush)
public HttpOutput.Interceptor getNextInterceptor()
getNextInterceptor
in interface HttpOutput.Interceptor
public boolean isOptimizedForDirectBuffers()
isOptimizedForDirectBuffers
in interface HttpOutput.Interceptor
ByteBuffer
s in the HttpOutput.Interceptor.write(ByteBuffer, boolean, Callback)
method. If false is returned, then passing direct buffers may cause
inefficiencies.public void write(java.nio.ByteBuffer content, boolean complete, org.eclipse.jetty.util.Callback callback)
HttpOutput.Interceptor
write
in interface HttpOutput.Interceptor
content
- The content to be written or an empty buffer.complete
- True if this is the last call to writecallback
- The callback to use to indicate Callback.succeeded()
or Callback.failed(Throwable)
.protected void commit(java.nio.ByteBuffer content, boolean complete, org.eclipse.jetty.util.Callback callback)
public void noCompression()
public void noCompressionIfPossible()
public boolean mightCompress()
Copyright © 1995–2018 Webtide. All rights reserved.