public abstract class HTTPBase
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected static Logger |
_logger |
protected java.nio.charset.Charset |
_responseCharset |
protected int |
_responseCode |
protected java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
_responseHeaders |
protected int |
DEFAULT_HTTP_RESPONSECODE |
static boolean |
ShowConnectionTrace |
Constructor and Description |
---|
HTTPBase() |
Modifier and Type | Method and Description |
---|---|
abstract byte[] |
getByteArrayResponse()
Get the response as byte array.
|
int |
getLastResponse()
Get the HTTP response code of the last request.
|
abstract int |
getResponse()
Establish the connection and returns the status.
|
java.util.Map<java.lang.String,java.util.List<java.lang.String>> |
getResponseHeaders()
Get the HTTP response headers.
|
abstract java.io.InputStream |
getStreamResponse()
Get the response as stream.
|
protected static java.lang.String |
getStringCode(int code) |
abstract java.lang.String |
getStringResponse()
Get the response as string encoded in charset recovered in response headers.
|
abstract java.lang.String |
getStringResponse(java.nio.charset.Charset charset)
Get the response as string.
|
static void |
SetTlsClientCompatibleAlgorithm()
Restricts the client authentication signature schemes to 'rsa_pkcs1'.
|
protected static final Logger _logger
protected final int DEFAULT_HTTP_RESPONSECODE
public static boolean ShowConnectionTrace
protected java.nio.charset.Charset _responseCharset
protected int _responseCode
protected java.util.Map<java.lang.String,java.util.List<java.lang.String>> _responseHeaders
public static void SetTlsClientCompatibleAlgorithm()
public abstract int getResponse() throws java.io.IOException
java.io.IOException
- if exception occurs.public abstract java.io.InputStream getStreamResponse() throws java.io.IOException
java.io.IOException
- if exception occurs.public abstract java.lang.String getStringResponse() throws java.io.IOException
java.io.IOException
- if exception occurs.public abstract java.lang.String getStringResponse(java.nio.charset.Charset charset) throws java.io.IOException
charset
- Character encoding.java.io.IOException
- if exception occurs.public abstract byte[] getByteArrayResponse() throws java.io.IOException
java.io.IOException
- if exception occurs.public int getLastResponse() throws java.io.IOException
java.io.IOException
- if there is no previous request.public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getResponseHeaders() throws java.io.IOException
java.io.IOException
- if there is no previous request.protected static java.lang.String getStringCode(int code)