JBoss EJB client 1.0.5.Final

org.jboss.ejb.client
Class ClusterContext

java.lang.Object
  extended by org.jboss.ejb.client.ClusterContext

public final class ClusterContext
extends Object

A ClusterContext keeps track of a specific cluster and the ClusterNodes in that cluster. A ClusterContext is always associated with a EJBClientContext

Author:
Jaikiran Pai

Method Summary
 void addClusterNode(String nodeName, ClusterNodeManager clusterNodeManager)
          Adds a cluster node and the ClusterNodeManager associated with that node, to this cluster context
 String getClusterName()
           
 EJBClientContext getEJBClientContext()
           
 void receiverContextClosed(EJBReceiverContext receiverContext)
          A callback method which will be invoked when the receiverContext is closed.
 void registerEJBReceiver(EJBReceiver receiver)
          Register a EJBReceiver with this cluster context
 void removeAllClusterNodes()
          Removes all previously associated cluster node(s), if any, from this cluster context
 void removeClusterNode(String nodeName)
          Removes a previously assoicated cluster node, if any, from this cluster context.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getClusterName

public String getClusterName()

getEJBClientContext

public EJBClientContext getEJBClientContext()

addClusterNode

public void addClusterNode(String nodeName,
                           ClusterNodeManager clusterNodeManager)
Adds a cluster node and the ClusterNodeManager associated with that node, to this cluster context

Parameters:
nodeName - The cluster node name
clusterNodeManager - The cluster node manager for that node

removeClusterNode

public void removeClusterNode(String nodeName)
Removes a previously assoicated cluster node, if any, from this cluster context.

Parameters:
nodeName - The node name

removeAllClusterNodes

public void removeAllClusterNodes()
Removes all previously associated cluster node(s), if any, from this cluster context


registerEJBReceiver

public void registerEJBReceiver(EJBReceiver receiver)
Register a EJBReceiver with this cluster context

Parameters:
receiver - The EJB receiver for that node

receiverContextClosed

public void receiverContextClosed(EJBReceiverContext receiverContext)
A callback method which will be invoked when the receiverContext is closed. This method can do the necessary cleanup (if any) of resources associated with the receiver context

Parameters:
receiverContext - The receiver context which was closed

JBoss EJB client 1.0.5.Final

Copyright © 2012 JBoss by Red Hat. All Rights Reserved.