org.apache.http.impl.nio.client
Class MinimalClientExchangeHandlerImpl<T>

java.lang.Object
  extended by org.apache.http.impl.nio.client.MinimalClientExchangeHandlerImpl<T>
All Implemented Interfaces:
Closeable, Cancellable, org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler

public class MinimalClientExchangeHandlerImpl<T>
extends Object
implements org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler, Cancellable


Constructor Summary
MinimalClientExchangeHandlerImpl(org.apache.commons.logging.Log log, org.apache.http.nio.protocol.HttpAsyncRequestProducer requestProducer, org.apache.http.nio.protocol.HttpAsyncResponseConsumer<T> responseConsumer, HttpClientContext localContext, BasicFuture<T> resultFuture, NHttpClientConnectionManager connmgr, HttpProcessor httpProcessor, ConnectionReuseStrategy connReuseStrategy, ConnectionKeepAliveStrategy keepaliveStrategy)
           
 
Method Summary
 boolean cancel()
           
 void close()
           
 void consumeContent(org.apache.http.nio.ContentDecoder decoder, org.apache.http.nio.IOControl ioctrl)
           
 void failed(Exception ex)
           
 HttpRequest generateRequest()
           
 void inputTerminated()
           
 boolean isDone()
           
 void produceContent(org.apache.http.nio.ContentEncoder encoder, org.apache.http.nio.IOControl ioctrl)
           
 void requestCompleted()
           
 void responseCompleted()
           
 void responseReceived(HttpResponse response)
           
 void start()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MinimalClientExchangeHandlerImpl

public MinimalClientExchangeHandlerImpl(org.apache.commons.logging.Log log,
                                        org.apache.http.nio.protocol.HttpAsyncRequestProducer requestProducer,
                                        org.apache.http.nio.protocol.HttpAsyncResponseConsumer<T> responseConsumer,
                                        HttpClientContext localContext,
                                        BasicFuture<T> resultFuture,
                                        NHttpClientConnectionManager connmgr,
                                        HttpProcessor httpProcessor,
                                        ConnectionReuseStrategy connReuseStrategy,
                                        ConnectionKeepAliveStrategy keepaliveStrategy)
Method Detail

close

public void close()
Specified by:
close in interface Closeable

start

public void start()
           throws HttpException,
                  IOException
Throws:
HttpException
IOException

isDone

public boolean isDone()
Specified by:
isDone in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler

generateRequest

public HttpRequest generateRequest()
                            throws IOException,
                                   HttpException
Specified by:
generateRequest in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler
Throws:
IOException
HttpException

produceContent

public void produceContent(org.apache.http.nio.ContentEncoder encoder,
                           org.apache.http.nio.IOControl ioctrl)
                    throws IOException
Specified by:
produceContent in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler
Throws:
IOException

requestCompleted

public void requestCompleted()
Specified by:
requestCompleted in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler

responseReceived

public void responseReceived(HttpResponse response)
                      throws IOException,
                             HttpException
Specified by:
responseReceived in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler
Throws:
IOException
HttpException

consumeContent

public void consumeContent(org.apache.http.nio.ContentDecoder decoder,
                           org.apache.http.nio.IOControl ioctrl)
                    throws IOException
Specified by:
consumeContent in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler
Throws:
IOException

responseCompleted

public void responseCompleted()
                       throws IOException,
                              HttpException
Specified by:
responseCompleted in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler
Throws:
IOException
HttpException

inputTerminated

public void inputTerminated()
Specified by:
inputTerminated in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler

failed

public void failed(Exception ex)
Specified by:
failed in interface org.apache.http.nio.protocol.HttpAsyncClientExchangeHandler

cancel

public boolean cancel()
Specified by:
cancel in interface Cancellable


Copyright © 2010-2013 The Apache Software Foundation. All Rights Reserved.