public class HttpResponseEncoder extends HttpObjectEncoder<HttpResponse>
ChannelHandler.Sharable | Constructor and Description |
|---|
HttpResponseEncoder () |
| Modifier and Type | Method and Description |
|---|---|
boolean |
acceptOutboundMessage (Object msg)
Returns
true if the given message should be handled. |
protected void |
encodeInitialLine (ByteBuf buf,
HttpResponse response) |
protected boolean |
isContentAlwaysEmpty (HttpResponse msg)
Determine whether a message has a content or not.
|
protected void |
sanitizeHeadersBeforeEncode (HttpResponse msg,
boolean isAlwaysEmpty)
Allows to sanitize headers of the message before encoding these.
|
encode, encodeAscii, encodeHeaders, write bind, close, connect, deregister, disconnect, flush, read ensureNotSharable, exceptionCaught, handlerAdded, handlerRemoved, isSharable clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait exceptionCaught, handlerAdded, handlerRemoved public HttpResponseEncoder()
public boolean acceptOutboundMessage(Object msg) throws Exception
MessageToMessageEncoder true if the given message should be handled. If false it will be passed to the next
ChannelOutboundHandler in the ChannelPipeline.acceptOutboundMessage in class HttpObjectEncoder<HttpResponse>Exception protected void encodeInitialLine(ByteBuf buf, HttpResponse response) throws Exception
encodeInitialLine in class HttpObjectEncoder<HttpResponse>Exception protected void sanitizeHeadersBeforeEncode(HttpResponse msg, boolean isAlwaysEmpty)
HttpObjectEncoder sanitizeHeadersBeforeEncode in class HttpObjectEncoder<HttpResponse>protected boolean isContentAlwaysEmpty(HttpResponse msg)
HttpObjectEncoder isContentAlwaysEmpty in class HttpObjectEncoder<HttpResponse>msg - the message to testtrue to signal the message has no contentCopyright © 2008–2025 The Netty Project. All rights reserved.