ClientSession
| Modifier and Type | Class and Description |
|---|---|
| private static class | ClientSessionImpl.
Encapsulates and protects against concurrent access the service switching. |
| Modifier and Type | Field and Description |
|---|---|
| private final AtomicReference | authErrorHolder
Also guards setting an earlyError and the authFuture together. |
| private volatile AuthFuture | authFuture
The authentication future created by the last call to |
| private final AtomicReference | |
| private final AtomicBoolean | |
| private Map | metadataMap
For clients to store their own metadata |
| Access | Constructor and Description |
|---|---|
| public |
| authErrorHolder | back to summary |
|---|---|
| private final AtomicReference<Throwable> authErrorHolder Also guards setting an earlyError and the authFuture together. | |
| authFuture | back to summary |
|---|---|
| private volatile AuthFuture authFuture The authentication future created by the last call to | |
| beforeAuthErrorHolder | back to summary |
|---|---|
| private final AtomicReference<Throwable> beforeAuthErrorHolder | |
| initialServiceRequestSent | back to summary |
|---|---|
| private final AtomicBoolean initialServiceRequestSent | |
| metadataMap | back to summary |
|---|---|
| private Map<Object, Object> metadataMap For clients to store their own metadata | |
| ClientSessionImpl | back to summary |
|---|---|
| public ClientSessionImpl(ClientFactoryManager client, IoSession ioSession) throws Exception | |
| auth | back to summary |
|---|---|
| public AuthFuture auth() throws IOException Implements org. Doc from org. Starts the authentication process. User identities will be tried until the server successfully authenticate the
user. User identities must be provided before calling this method using
| |
| exceptionCaught | back to summary |
|---|---|
| public void exceptionCaught(Throwable t) Overrides org. Implements org. Doc from org. Handle any exceptions that occurred on this session. The session will be closed and a disconnect packet will be
sent before if the given exception is an | |
| getCurrentServices | back to summary |
|---|---|
| private ClientSessionImpl. | |
| getMetadataMap | back to summary |
|---|---|
| public Map Implements org. Doc from org. Access to the metadata. | |
| getServices | back to summary |
|---|---|
| protected List Overrides org.
| |
| getSessionState | back to summary |
|---|---|
| public Set Implements org.
| |
| handleDisconnect | back to summary |
|---|---|
| protected void handleDisconnect(int code, String msg, String lang, Buffer buffer) throws Exception Overrides org.
| |
| initializeCurrentService | back to summary |
|---|---|
| protected CurrentService initializeCurrentService() Overrides org. Doc from org. Creates a new
This initialization method is invoked once from the
| |
| nextServiceName | back to summary |
|---|---|
| protected String nextServiceName() | |
| preClose | back to summary |
|---|---|
| protected void preClose() Overrides org. Doc from org. preClose is guaranteed to be called before doCloseGracefully or doCloseImmediately. When preClose() is called, isClosing() == true
| |
| sendInitialServiceRequest | back to summary |
|---|---|
| protected void sendInitialServiceRequest() throws IOException | |
| signalAuthFailure | back to summary |
|---|---|
| protected void signalAuthFailure(Throwable t) | |
| signalSessionEvent | back to summary |
|---|---|
| protected void signalSessionEvent(SessionListener. Overrides org. Doc from org. Sends a session event to all currently registered session listeners
| |
| switchToNextService | back to summary |
|---|---|
| public void switchToNextService() throws IOException | |
| updateCurrentSessionState | back to summary |
|---|---|
| protected <C extends Collection | |
| waitFor | back to summary |
|---|---|
| public Set Implements org. Doc from org. Wait for any one of a specific state to be signaled.
| |
| Modifier and Type | Field and Description |
|---|---|
| private Service | |
| private String |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv synchronized Service | |
| pack-priv synchronized String | |
| pack-priv synchronized void | |
| pack-priv synchronized void |
| next | back to summary |
|---|---|
| private Service next | |
| nextName | back to summary |
|---|---|
| private String nextName | |
| Services | back to summary |
|---|---|
| pack-priv Services(ClientSessionImpl session) | |
| getNext | back to summary |
|---|---|
| pack-priv synchronized Service getNext() | |
| getNextName | back to summary |
|---|---|
| pack-priv synchronized String getNextName() | |
| initialize | back to summary |
|---|---|
| pack-priv synchronized void initialize(List<? extends ServiceFactory> factories) throws IOException | |
| switchServices | back to summary |
|---|---|
| pack-priv synchronized void switchServices() throws IOException | |