public class HTTPSProperties extends Object
HttpsURLConnection.
An instance of this class may be added as a property of the Client
or ClientRequest using the property name
PROPERTY_HTTPS_PROPERTIES.
| Modifier and Type | Field and Description |
|---|---|
static String |
PROPERTY_HTTPS_PROPERTIES
HTTPS properties property.
|
| Constructor and Description |
|---|
HTTPSProperties()
Construct default properties with no
HostnameVerifier
and a SSLContext constructed using SSLContext.getInstance("SSL"). |
HTTPSProperties(HostnameVerifier hv)
|
HTTPSProperties(HostnameVerifier hv,
SSLContext c)
Construct with a
HostnameVerifier and a SSLContext. |
| Modifier and Type | Method and Description |
|---|---|
HostnameVerifier |
getHostnameVerifier()
Get the P
HostnameVerifier. |
SSLContext |
getSSLContext()
Get the
SSLContext. |
void |
setConnection(HttpsURLConnection connection)
Set the
HttpsURLConnection with the HTTPS properties. |
public static final String PROPERTY_HTTPS_PROPERTIES
HTTPSProperties.
If the property is absent then HTTPS properties will not be used.public HTTPSProperties()
throws NoSuchAlgorithmException
HostnameVerifier
and a SSLContext constructed using SSLContext.getInstance("SSL").NoSuchAlgorithmException - if the SSLContext could not
be created.public HTTPSProperties(HostnameVerifier hv) throws NoSuchAlgorithmException
hv - the HostnameVerifier.NoSuchAlgorithmException - if the SSLContext could not
be created.public HTTPSProperties(HostnameVerifier hv, SSLContext c)
HostnameVerifier and a SSLContext.hv - the HostnameVerifier.c - the SSLContext. Must not be null.public HostnameVerifier getHostnameVerifier()
HostnameVerifier.null if not set
at construction.public SSLContext getSSLContext()
SSLContext.public void setConnection(HttpsURLConnection connection)
HttpsURLConnection with the HTTPS properties.connection - the HttpsURLConnection.Copyright © 2014 Oracle Corporation. All rights reserved.