public abstract class Protocol extends Object
Modifier and Type | Field and Description |
---|---|
protected ChannelManager |
channelManager |
protected AsyncHttpClientConfig |
config |
protected boolean |
hasIOExceptionFilters |
protected org.slf4j.Logger |
logger |
protected NettyAsyncHttpProviderConfig |
nettyConfig |
static Set<Integer> |
REDIRECT_STATUSES |
protected NettyRequestSender |
requestSender |
Constructor and Description |
---|
Protocol(ChannelManager channelManager,
AsyncHttpClientConfig config,
NettyAsyncHttpProviderConfig nettyConfig,
NettyRequestSender requestSender) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
exitAfterHandlingRedirect(org.jboss.netty.channel.Channel channel,
NettyResponseFuture<?> future,
org.jboss.netty.handler.codec.http.HttpResponse response,
Request request,
int statusCode) |
protected boolean |
exitAfterProcessingFilters(org.jboss.netty.channel.Channel channel,
NettyResponseFuture<?> future,
AsyncHandler<?> handler,
HttpResponseStatus status,
HttpResponseHeaders responseHeaders) |
abstract void |
handle(org.jboss.netty.channel.Channel channel,
NettyResponseFuture<?> future,
Object message) |
abstract void |
onClose(org.jboss.netty.channel.Channel channel) |
abstract void |
onError(org.jboss.netty.channel.Channel channel,
Throwable e) |
protected final org.slf4j.Logger logger
protected final ChannelManager channelManager
protected final AsyncHttpClientConfig config
protected final NettyAsyncHttpProviderConfig nettyConfig
protected final NettyRequestSender requestSender
protected final boolean hasIOExceptionFilters
public Protocol(ChannelManager channelManager, AsyncHttpClientConfig config, NettyAsyncHttpProviderConfig nettyConfig, NettyRequestSender requestSender)
public abstract void handle(org.jboss.netty.channel.Channel channel, NettyResponseFuture<?> future, Object message) throws Exception
Exception
public abstract void onError(org.jboss.netty.channel.Channel channel, Throwable e)
public abstract void onClose(org.jboss.netty.channel.Channel channel)
protected boolean exitAfterHandlingRedirect(org.jboss.netty.channel.Channel channel, NettyResponseFuture<?> future, org.jboss.netty.handler.codec.http.HttpResponse response, Request request, int statusCode) throws Exception
Exception
protected boolean exitAfterProcessingFilters(org.jboss.netty.channel.Channel channel, NettyResponseFuture<?> future, AsyncHandler<?> handler, HttpResponseStatus status, HttpResponseHeaders responseHeaders) throws IOException
IOException
Copyright © 2014. All Rights Reserved.