public final class ConnectionSpecSelector extends Object
| Constructor and Description |
|---|
ConnectionSpecSelector(List
|
| Modifier and Type | Method and Description |
|---|---|
ConnectionSpec |
configureSecureSocket(SSLSocket
Configures the supplied
SSLSocket to connect to the specified host using an appropriate
ConnectionSpec.
|
boolean |
connectionFailed(IOException
Reports a failure to complete a connection.
|
public ConnectionSpecSelector(List<ConnectionSpec > connectionSpecs)
public ConnectionSpecconfigureSecureSocket(SSLSocket sslSocket) throws IOException
SSLSocket to connect to the specified host using an appropriate
ConnectionSpec. Returns the chosen
ConnectionSpec, never
null.
IOException - if the socket does not support any of the TLS modes available
public boolean connectionFailed(IOExceptione)
ConnectionSpec to try, if any.
true if the connection should be retried using
configureSecureSocket(SSLSocket) or
false if not