org.jboss.netty.handler.codec.http2
Class HttpClientCodec
java.lang.Object
org.jboss.netty.handler.codec.http2.HttpClientCodec
- All Implemented Interfaces:
- org.jboss.netty.channel.ChannelDownstreamHandler, org.jboss.netty.channel.ChannelHandler, org.jboss.netty.channel.ChannelUpstreamHandler
public class HttpClientCodec
- extends Object
- implements org.jboss.netty.channel.ChannelUpstreamHandler, org.jboss.netty.channel.ChannelDownstreamHandler
A combination of HttpRequestEncoder
and HttpResponseDecoder
which enables easier client side HTTP implementation. HttpClientCodec
provides additional state management for HEAD and CONNECT
requests, which HttpResponseDecoder
lacks. Please refer to
HttpResponseDecoder
to learn what additional state management needs
to be done for HEAD and CONNECT and why
HttpResponseDecoder
can not handle it by itself.
- Version:
- $Rev: 1108 $, $Date: 2012-04-21 12:51:25 +0200 (sam., 21 avr. 2012) $
- Author:
- The Netty Project, Trustin Lee
- See Also:
HttpServerCodec
Nested classes/interfaces inherited from interface org.jboss.netty.channel.ChannelHandler |
org.jboss.netty.channel.ChannelHandler.Sharable |
Constructor Summary |
HttpClientCodec()
Creates a new instance with the default decoder options
(maxInitialLineLength (4096 }, maxHeaderSize (8192) , and
maxChunkSize (8192) ). |
HttpClientCodec(int maxInitialLineLength,
int maxHeaderSize,
int maxChunkSize)
Creates a new instance with the specified decoder options. |
HttpClientCodec(int maxInitialLineLength,
int maxHeaderSize,
int maxChunkSize,
boolean failOnMissingResponse)
Creates a new instance with the specified decoder options. |
Method Summary |
void |
handleDownstream(org.jboss.netty.channel.ChannelHandlerContext ctx,
org.jboss.netty.channel.ChannelEvent e)
|
void |
handleUpstream(org.jboss.netty.channel.ChannelHandlerContext ctx,
org.jboss.netty.channel.ChannelEvent e)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HttpClientCodec
public HttpClientCodec()
- Creates a new instance with the default decoder options
(
maxInitialLineLength (4096
}, maxHeaderSize (8192)
, and
maxChunkSize (8192)
).
HttpClientCodec
public HttpClientCodec(int maxInitialLineLength,
int maxHeaderSize,
int maxChunkSize)
- Creates a new instance with the specified decoder options.
HttpClientCodec
public HttpClientCodec(int maxInitialLineLength,
int maxHeaderSize,
int maxChunkSize,
boolean failOnMissingResponse)
- Creates a new instance with the specified decoder options.
handleUpstream
public void handleUpstream(org.jboss.netty.channel.ChannelHandlerContext ctx,
org.jboss.netty.channel.ChannelEvent e)
throws Exception
- Specified by:
handleUpstream
in interface org.jboss.netty.channel.ChannelUpstreamHandler
- Throws:
Exception
handleDownstream
public void handleDownstream(org.jboss.netty.channel.ChannelHandlerContext ctx,
org.jboss.netty.channel.ChannelEvent e)
throws Exception
- Specified by:
handleDownstream
in interface org.jboss.netty.channel.ChannelDownstreamHandler
- Throws:
Exception
Copyright © 2009-2012 Frederic Bregier. All Rights Reserved.