StatefulProxyConnector.
| Modifier and Type | Field and Description |
|---|---|
| private List | |
| private static final long | |
| private boolean | |
| private long | |
| private final Object | lock
Guards |
| protected final InetSocketAddress | proxyAddress
The proxy address. |
| protected char[] | proxyPassword
The password to use for authentication at the proxy. |
| protected String | proxyUser
The user to authenticate at the proxy with. |
| private long | |
| protected final InetSocketAddress | remoteAddress
The ultimate remote address to connect to. |
| private AtomicReference |
| Access | Constructor and Description |
|---|---|
| public | AbstractClientProxyConnector(InetSocketAddress
of the proxy server we're connecting to proxyAddress, InetSocketAddress of the target server to connect to remoteAddress, String to authenticate at the proxy with; may be proxyUser, char[] nullto authenticate at the proxy with; may be proxyPassword)nullCreates a new |
| Modifier and Type | Method and Description |
|---|---|
| protected void | adjustTimeout()
Adjusts the timeout calculation to not account of elapsed time since the last time the timeout was gotten. |
| protected void | |
| protected long | Returns: the timeout in milliseconds, always > 0LObtains the timeout for the whole rest of the proxy connection protocol. |
| protected void | |
| public void | runWhenDone(Callable<Void>
operation to run starter)Implements org. Runs |
| protected void |
| bufferedCommands | back to summary |
|---|---|
| private List<Callable<Void>> bufferedCommands | |
| DEFAULT_PROXY_TIMEOUT_NANOS | back to summary |
|---|---|
| private static final long DEFAULT_PROXY_TIMEOUT_NANOS | |
| done | back to summary |
|---|---|
| private boolean done | |
| lastProxyOperationTime | back to summary |
|---|---|
| private long lastProxyOperationTime | |
| lock | back to summary |
|---|---|
| private final Object lock Guards | |
| proxyAddress | back to summary |
|---|---|
| protected final InetSocketAddress proxyAddress The proxy address. | |
| proxyPassword | back to summary |
|---|---|
| protected char[] proxyPassword The password to use for authentication at the proxy. | |
| proxyUser | back to summary |
|---|---|
| protected String proxyUser The user to authenticate at the proxy with. | |
| remainingProxyProtocolTime | back to summary |
|---|---|
| private long remainingProxyProtocolTime | |
| remoteAddress | back to summary |
|---|---|
| protected final InetSocketAddress remoteAddress The ultimate remote address to connect to. | |
| unregister | back to summary |
|---|---|
| private AtomicReference<Runnable> unregister | |
| AbstractClientProxyConnector | back to summary |
|---|---|
| public AbstractClientProxyConnector(InetSocketAddress proxyAddress, InetSocketAddress remoteAddress, String proxyUser, char[] proxyPassword) Creates a new
| |
| adjustTimeout | back to summary |
|---|---|
| protected void adjustTimeout() Adjusts the timeout calculation to not account of elapsed time since the last time the timeout was gotten. Can be used for instance to ignore time spent in user dialogs be counted against the overall proxy connection protocol timeout. | |
| clearPassword | back to summary |
|---|---|
| protected void clearPassword() Clears the proxy password. | |
| getTimeout | back to summary |
|---|---|
| protected long getTimeout() Obtains the timeout for the whole rest of the proxy connection protocol.
| |
| init | back to summary |
|---|---|
| protected void init(ClientSession session) Initializes this instance. Installs itself as proxy handler on the session.
| |
| runWhenDone | back to summary |
|---|---|
| public void runWhenDone(Callable<Void> starter) throws Exception Implements org. Doc from org. Runs | |
| setDone | back to summary |
|---|---|
| protected void setDone(boolean success) throws Exception Sets the "done" flag.
| |