Class HttpClient
java.lang.Object
org.sblim.wbem.http.HttpClient
- All Implemented Interfaces:
EventListener, HandshakeCompletedListener
-
Constructor Summary
ConstructorsConstructorDescriptionHttpClient
(URI url, HttpClientPool clientPool, AuthorizationHandler auth_handler) -
Method Summary
Modifier and TypeMethodDescriptionvoid
connect()
static String
convertToHexString
(byte[] digest) protected static String
void
void
finalize()
protected AuthInfo
getAuthentication
(boolean proxy, AuthInfo prevAuthInfo, String authenticate) static HttpClient
getClient
(URI url, HttpClientPool clientPool, AuthorizationHandler auth_handler) getHeaderField
(int index) getHeaderField
(String name) getHeaderFieldKey
(int index) getRequestProperty
(String key) int
protected static void
void
boolean
Returns connectedprotected static byte[]
void
reset()
void
setRequestMethod
(String method) void
setRequestProperty
(String key, String value) void
void
streamFinished
(boolean keep) void
useHttp11
(boolean bool) boolean
-
Constructor Details
-
HttpClient
-
-
Method Details
-
convertToHexString
-
getClient
public static HttpClient getClient(URI url, HttpClientPool clientPool, AuthorizationHandler auth_handler) -
dequote
-
handleRsp
- Throws:
IOException
-
parseHex
-
connect
- Throws:
IOException
-
disconnect
public void disconnect() -
finalize
-
getCipherSuite
-
getHeaderField
-
getHeaderField
-
getHeaderFieldKey
-
getInputStream
- Throws:
IOException
-
getOutputStream
- Throws:
IOException
-
getRequestMethod
-
getRequestProperty
-
getResponseCode
- Throws:
IOException
-
getResponseMessage
-
handshakeCompleted
- Specified by:
handshakeCompleted
in interfaceHandshakeCompletedListener
-
reset
public void reset() -
setRequestMethod
-
setRequestProperty
-
streamFinished
public void streamFinished() -
streamFinished
public void streamFinished(boolean keep) -
useHttp11
public void useHttp11(boolean bool) -
usingProxy
public boolean usingProxy() -
getAuthentication
protected AuthInfo getAuthentication(boolean proxy, AuthInfo prevAuthInfo, String authenticate) throws HttpParseException, NoSuchAlgorithmException -
isConnected
public boolean isConnected()Returns connected- Returns:
- The value of connected.
-