public final class PerMessageDeflateExtension extends Object implements WebSocketExtension
| Constructor and Description |
|---|
PerMessageDeflateExtension() |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Releases any native resources held by this extension (e.g. a
Deflater or
Inflater). |
ByteBuffer |
decode(WebSocketFrameType type,
boolean fin,
ByteBuffer payload) |
ByteBuffer |
decode(WebSocketFrameType type,
boolean fin,
ByteBuffer payload,
long maxOutputSize)
Decode a frame payload, aborting as soon as the produced output exceeds
maxOutputSize. |
ByteBuffer |
encode(WebSocketFrameType type,
boolean fin,
ByteBuffer payload) |
String |
getName() |
WebSocketExtensionData |
getResponseData() |
boolean |
usesRsv1() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitusesRsv2, usesRsv3public String getName()
getName in interface WebSocketExtensionpublic boolean usesRsv1()
usesRsv1 in interface WebSocketExtensionpublic ByteBuffer decode(WebSocketFrameType type, boolean fin, ByteBuffer payload) throws WebSocketException
decode in interface WebSocketExtensionWebSocketExceptionpublic ByteBuffer decode(WebSocketFrameType type, boolean fin, ByteBuffer payload, long maxOutputSize) throws WebSocketException
WebSocketExtensionmaxOutputSize. A non-positive limit means no limit. Implementations
that may expand input (e.g. permessage-deflate) MUST honour the limit during
the expansion step, not only after it, to prevent decompression-bomb attacks.decode in interface WebSocketExtensionWebSocketExceptionpublic ByteBuffer encode(WebSocketFrameType type, boolean fin, ByteBuffer payload) throws WebSocketException
encode in interface WebSocketExtensionWebSocketExceptionpublic WebSocketExtensionData getResponseData()
getResponseData in interface WebSocketExtensionpublic void close()
WebSocketExtensionDeflater or
Inflater). Called once when the owning session terminates.close in interface WebSocketExtensionCopyright © 1999–2021 The Apache Software Foundation. All rights reserved.