public class NoopCacheCluster extends Object implements CacheCluster
| Modifier and Type | Field and Description |
|---|---|
static CacheCluster |
INSTANCE
A singleton instance you can use rather than constructing your own.
|
| Constructor and Description |
|---|
NoopCacheCluster() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addTopologyListener(ClusterTopologyListener listener)
Add a listener for cluster events
|
ClusterNode |
getCurrentNode()
Retrieves the
ClusterNode instance that corresponds to the current node. |
Collection<ClusterNode> |
getNodes()
Get all the nodes in the cluster
|
ClusterScheme |
getScheme()
Always returns the ClusterScheme.NONE
|
List<ClusterTopologyListener> |
getTopologyListeners()
Get all the topology listeners
|
boolean |
isClusterOnline()
Find out if the current node is connected to the cluster or not
|
boolean |
removeTopologyListener(ClusterTopologyListener listener)
Remove a listener for cluster events
|
ClusterNode |
waitUntilNodeJoinsCluster()
Waits until the current node has successfully joined the cluster.
|
public static final CacheCluster INSTANCE
public Collection<ClusterNode> getNodes()
getNodes in interface CacheClusterpublic ClusterScheme getScheme()
getScheme in interface CacheClusterClusterScheme.NONEpublic boolean addTopologyListener(ClusterTopologyListener listener)
addTopologyListener in interface CacheClusterlistener - Listenerpublic boolean removeTopologyListener(ClusterTopologyListener listener)
removeTopologyListener in interface CacheClusterlistener - Listenerpublic boolean isClusterOnline()
isClusterOnline in interface CacheClusterpublic ClusterNode getCurrentNode()
ClusterNode instance that corresponds to the current node.getCurrentNode in interface CacheClusterClusterNode instance that corresponds to the current nodepublic ClusterNode waitUntilNodeJoinsCluster()
waitUntilNodeJoinsCluster in interface CacheClusterClusterNode instance that corresponds to the current nodepublic List<ClusterTopologyListener> getTopologyListeners()
getTopologyListeners in interface CacheClusterCopyright © 2003-2014 Terracotta, Inc.. All Rights Reserved.