HTTPClient
Class StubHTTPConnection

java.lang.Object
  extended by HTTPClient.HTTPConnection
      extended by HTTPClient.StubHTTPConnection
All Implemented Interfaces:
HTTPClientModuleConstants

public class StubHTTPConnection
extends HTTPConnection

Override HTTPConnection so unit tests can get at its internals.

Author:
Philip Aston

Nested Class Summary
 
Nested classes/interfaces inherited from class HTTPClient.HTTPConnection
HTTPConnection.BandwidthLimiter, HTTPConnection.BandwidthLimiterFactory, HTTPConnection.TimeAuthority
 
Field Summary
static int CD_0
           
static int CD_CHUNKED
           
static int CD_CLOSE
           
static int CD_CONTLEN
           
static int CD_HDRS
           
static int CD_MP_BR
           
static int CD_NONE
           
static int HTTP
           
static int HTTP_1_0
           
static int HTTP_1_1
           
static int HTTP_NG
           
static int HTTPS
           
static int SHTTP
           
 
Fields inherited from class HTTPClient.HTTPConnection
version
 
Fields inherited from interface HTTPClient.HTTPClientModuleConstants
REQ_CONTINUE, REQ_NEWCON_RST, REQ_NEWCON_SND, REQ_RESPONSE, REQ_RESTART, REQ_RETURN, REQ_SHORTCIRC, RSP_CONTINUE, RSP_NEWCON_REQ, RSP_NEWCON_SND, RSP_REQUEST, RSP_RESTART, RSP_SEND, RSP_SHORTCIRC
 
Constructor Summary
StubHTTPConnection(String host)
           
 
Method Summary
 HTTPConnection.BandwidthLimiterFactory getBandwithLimiterFactoryForTest()
           
 InetAddress getLocalAddressForTest()
           
 
Methods inherited from class HTTPClient.HTTPConnection
addBasicAuthorization, addDefaultModule, addDigestAuthorization, addModule, Delete, Delete, dontProxyFor, dontProxyFor, doProxyFor, ExtensionMethod, ExtensionMethod, Get, Get, Get, Get, Get, getAllowUserInteraction, getCheckCertificates, getConnectionsEstablished, getConnectTime, getContext, getDefaultAllowUserInteraction, getDefaultContext, getDefaultHeaders, getDefaultModules, getDefaultSSLSocketFactory, getDefaultTimeout, getDnsTime, getHost, getModules, getPort, getProtocol, getProxyHost, getProxyPort, getSSLCipherSuites, getSSLProtocols, getSSLSocketFactory, getTestConnectionHealthWithBlockingRead, getTimeAuthority, getTimeout, Head, Head, Head, Head, Head, isCompatibleWith, Options, Options, Options, Options, Post, Post, Post, Post, Post, Post, Post, Post, Post, Put, Put, Put, Put, Put, Put, removeDefaultModule, removeModule, setAllowUserInteraction, setBufferGrowthStrategyFactory, setCheckCertificates, setContext, setCurrentProxy, setDefaultAllowUserInteraction, setDefaultHeaders, setDefaultSSLSocketFactory, setDefaultTimeout, setLocalAddress, setProxyServer, setRawMode, setSocksServer, setSocksServer, setSocksServer, setSSLSocketFactory, setTestConnectionHealthWithBlockingRead, setTimeAuthority, setTimeout, setupRequest, stop, toString, Trace, Trace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

HTTP

public static final int HTTP
See Also:
Constant Field Values

HTTPS

public static final int HTTPS
See Also:
Constant Field Values

SHTTP

public static final int SHTTP
See Also:
Constant Field Values

HTTP_NG

public static final int HTTP_NG
See Also:
Constant Field Values

HTTP_1_0

public static final int HTTP_1_0
See Also:
Constant Field Values

HTTP_1_1

public static final int HTTP_1_1
See Also:
Constant Field Values

CD_NONE

public static final int CD_NONE
See Also:
Constant Field Values

CD_HDRS

public static final int CD_HDRS
See Also:
Constant Field Values

CD_0

public static final int CD_0
See Also:
Constant Field Values

CD_CLOSE

public static final int CD_CLOSE
See Also:
Constant Field Values

CD_CONTLEN

public static final int CD_CONTLEN
See Also:
Constant Field Values

CD_CHUNKED

public static final int CD_CHUNKED
See Also:
Constant Field Values

CD_MP_BR

public static final int CD_MP_BR
See Also:
Constant Field Values
Constructor Detail

StubHTTPConnection

public StubHTTPConnection(String host)
Method Detail

getLocalAddressForTest

public InetAddress getLocalAddressForTest()

getBandwithLimiterFactoryForTest

public HTTPConnection.BandwidthLimiterFactory getBandwithLimiterFactoryForTest()


Copyright © 2000-2013. All Rights Reserved.