com.hazelcast.client.impl
Class ClientEndpointImpl

java.lang.Object
  extended by com.hazelcast.client.impl.ClientEndpointImpl
All Implemented Interfaces:
ClientEndpoint, Client, Endpoint

public final class ClientEndpointImpl
extends Object
implements Client, ClientEndpoint

The ClientEndpoint and Client implementation.


Method Summary
 void authenticated(ClientPrincipal principal)
           
 void authenticated(ClientPrincipal principal, Credentials credentials, boolean firstConnection)
           
 void clearAllListeners()
           
 void destroy()
           
 ClientType getClientType()
          Returns the type of this client.
 Connection getConnection()
           
 Credentials getCredentials()
           
 ClientPrincipal getPrincipal()
           
 InetSocketAddress getSocketAddress()
          Returns the socket address of this client.
 Subject getSubject()
           
 TransactionContext getTransactionContext(String txnId)
           
 String getUuid()
          Returns a unique uuid for this client.
 boolean isAlive()
          Checks if the endpoint is alive.
 boolean isAuthenticated()
           
 boolean isFirstConnection()
           
 void removeTransactionContext(String txnId)
           
 void sendEvent(Data key, Object event, int callId)
           
 void sendResponse(Object response, int callId)
           
 void setDistributedObjectListener(String id)
           
 void setListenerRegistration(String service, String topic, String id)
           
 void setLoginContext(LoginContext loginContext)
           
 void setTransactionContext(TransactionContext transactionContext)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getConnection

public Connection getConnection()
Specified by:
getConnection in interface ClientEndpoint

getUuid

public String getUuid()
Description copied from interface: Client
Returns a unique uuid for this client.

Specified by:
getUuid in interface ClientEndpoint
Specified by:
getUuid in interface Client
Specified by:
getUuid in interface Endpoint
Returns:
a unique uuid for this client

isAlive

public boolean isAlive()
Description copied from interface: ClientEndpoint
Checks if the endpoint is alive.

Specified by:
isAlive in interface ClientEndpoint
Returns:
true if alive, false otherwise.

setLoginContext

public void setLoginContext(LoginContext loginContext)
Specified by:
setLoginContext in interface ClientEndpoint

getSubject

public Subject getSubject()
Specified by:
getSubject in interface ClientEndpoint

isFirstConnection

public boolean isFirstConnection()
Specified by:
isFirstConnection in interface ClientEndpoint

authenticated

public void authenticated(ClientPrincipal principal,
                          Credentials credentials,
                          boolean firstConnection)
Specified by:
authenticated in interface ClientEndpoint

authenticated

public void authenticated(ClientPrincipal principal)
Specified by:
authenticated in interface ClientEndpoint

isAuthenticated

public boolean isAuthenticated()

getPrincipal

public ClientPrincipal getPrincipal()
Specified by:
getPrincipal in interface ClientEndpoint

getSocketAddress

public InetSocketAddress getSocketAddress()
Description copied from interface: Client
Returns the socket address of this client.

Specified by:
getSocketAddress in interface Client
Specified by:
getSocketAddress in interface Endpoint
Returns:
the socket address of this client

getClientType

public ClientType getClientType()
Description copied from interface: Client
Returns the type of this client.

Specified by:
getClientType in interface Client
Returns:
the type of this client

getTransactionContext

public TransactionContext getTransactionContext(String txnId)
Specified by:
getTransactionContext in interface ClientEndpoint

getCredentials

public Credentials getCredentials()

setTransactionContext

public void setTransactionContext(TransactionContext transactionContext)
Specified by:
setTransactionContext in interface ClientEndpoint

removeTransactionContext

public void removeTransactionContext(String txnId)
Specified by:
removeTransactionContext in interface ClientEndpoint

setListenerRegistration

public void setListenerRegistration(String service,
                                    String topic,
                                    String id)
Specified by:
setListenerRegistration in interface ClientEndpoint

setDistributedObjectListener

public void setDistributedObjectListener(String id)
Specified by:
setDistributedObjectListener in interface ClientEndpoint

clearAllListeners

public void clearAllListeners()
Specified by:
clearAllListeners in interface ClientEndpoint

destroy

public void destroy()
             throws LoginException
Throws:
LoginException

sendResponse

public void sendResponse(Object response,
                         int callId)
Specified by:
sendResponse in interface ClientEndpoint

sendEvent

public void sendEvent(Data key,
                      Object event,
                      int callId)
Specified by:
sendEvent in interface ClientEndpoint

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.