org.codehaus.wadi.servicespace.basic
Class BasicServiceSpace

java.lang.Object
  extended by org.codehaus.wadi.servicespace.basic.BasicServiceSpace
All Implemented Interfaces:
Lifecycle, ServiceSpace
Direct Known Subclasses:
AdminServiceSpace

public class BasicServiceSpace
extends java.lang.Object
implements ServiceSpace, Lifecycle

Version:
$Revision: $

Nested Class Summary
protected  class BasicServiceSpace.ServiceSpaceLifecycleEndpoint
           
 class BasicServiceSpace.UnderlyingClusterListener
           
 
Field Summary
protected  org.codehaus.wadi.group.Dispatcher dispatcher
           
protected  org.codehaus.wadi.group.Dispatcher underlyingDispatcher
           
 
Constructor Summary
BasicServiceSpace(ServiceSpaceName name, org.codehaus.wadi.group.Dispatcher underlyingDispatcher, ClassIndexerRegistry serviceClassIndexerRegistry)
           
 
Method Summary
 void addServiceSpaceListener(ServiceSpaceListener listener)
           
 boolean equals(java.lang.Object obj)
           
 org.codehaus.wadi.group.Dispatcher getDispatcher()
           
 java.util.Set getHostingPeers()
           
 org.codehaus.wadi.group.LocalPeer getLocalPeer()
           
 ServiceMonitor getServiceMonitor(ServiceName serviceName)
           
 ServiceProxyFactory getServiceProxyFactory(ServiceName serviceName, java.lang.Class[] interfaces)
           
 ServiceRegistry getServiceRegistry()
           
 ServiceSpaceName getServiceSpaceName()
           
protected  ServiceSpaceRegistry getServiceSpaceRegistry()
           
 org.codehaus.wadi.group.Dispatcher getUnderlyingDispatcher()
           
 int hashCode()
           
protected  org.codehaus.wadi.group.Dispatcher newDispatcher()
           
protected  ServiceMonitor newServiceMonitor(ServiceName serviceName)
           
protected  StartableServiceRegistry newServiceRegistry()
           
protected  ServiceSpaceRegistryFactory newServiceSpaceRegistryFactory()
           
protected  void notifyListeners(ServiceSpaceLifecycleEvent event, java.util.Set<org.codehaus.wadi.group.Peer> newHostingPeers)
           
protected  void processLifecycleEvent(ServiceSpaceLifecycleEvent event)
           
protected  void registerEndPoints()
           
protected  void registerServiceSpace()
           
 void removeServiceSpaceListener(ServiceSpaceListener listener)
           
protected  void sendLifecycleEventToCluster(LifecycleState state)
           
 void start()
           
 void stop()
           
 java.lang.String toString()
           
protected  void unregisterEndPoints()
           
protected  void unregisterServiceSpace()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

underlyingDispatcher

protected final org.codehaus.wadi.group.Dispatcher underlyingDispatcher

dispatcher

protected final org.codehaus.wadi.group.Dispatcher dispatcher
Constructor Detail

BasicServiceSpace

public BasicServiceSpace(ServiceSpaceName name,
                         org.codehaus.wadi.group.Dispatcher underlyingDispatcher,
                         ClassIndexerRegistry serviceClassIndexerRegistry)
Method Detail

getLocalPeer

public org.codehaus.wadi.group.LocalPeer getLocalPeer()
Specified by:
getLocalPeer in interface ServiceSpace

addServiceSpaceListener

public void addServiceSpaceListener(ServiceSpaceListener listener)
Specified by:
addServiceSpaceListener in interface ServiceSpace

getDispatcher

public org.codehaus.wadi.group.Dispatcher getDispatcher()
Specified by:
getDispatcher in interface ServiceSpace

getServiceSpaceName

public ServiceSpaceName getServiceSpaceName()
Specified by:
getServiceSpaceName in interface ServiceSpace

getHostingPeers

public java.util.Set getHostingPeers()
Specified by:
getHostingPeers in interface ServiceSpace

getServiceMonitor

public ServiceMonitor getServiceMonitor(ServiceName serviceName)
Specified by:
getServiceMonitor in interface ServiceSpace

getServiceRegistry

public ServiceRegistry getServiceRegistry()
Specified by:
getServiceRegistry in interface ServiceSpace

removeServiceSpaceListener

public void removeServiceSpaceListener(ServiceSpaceListener listener)
Specified by:
removeServiceSpaceListener in interface ServiceSpace

start

public void start()
           throws java.lang.Exception
Specified by:
start in interface Lifecycle
Throws:
java.lang.Exception

stop

public void stop()
          throws java.lang.Exception
Specified by:
stop in interface Lifecycle
Throws:
java.lang.Exception

getServiceProxyFactory

public ServiceProxyFactory getServiceProxyFactory(ServiceName serviceName,
                                                  java.lang.Class[] interfaces)
Specified by:
getServiceProxyFactory in interface ServiceSpace

getUnderlyingDispatcher

public org.codehaus.wadi.group.Dispatcher getUnderlyingDispatcher()

registerServiceSpace

protected void registerServiceSpace()

unregisterServiceSpace

protected void unregisterServiceSpace()

getServiceSpaceRegistry

protected ServiceSpaceRegistry getServiceSpaceRegistry()

newServiceSpaceRegistryFactory

protected ServiceSpaceRegistryFactory newServiceSpaceRegistryFactory()

newServiceRegistry

protected StartableServiceRegistry newServiceRegistry()

newDispatcher

protected org.codehaus.wadi.group.Dispatcher newDispatcher()

newServiceMonitor

protected ServiceMonitor newServiceMonitor(ServiceName serviceName)

registerEndPoints

protected void registerEndPoints()

unregisterEndPoints

protected void unregisterEndPoints()

sendLifecycleEventToCluster

protected void sendLifecycleEventToCluster(LifecycleState state)

notifyListeners

protected void notifyListeners(ServiceSpaceLifecycleEvent event,
                               java.util.Set<org.codehaus.wadi.group.Peer> newHostingPeers)

processLifecycleEvent

protected void processLifecycleEvent(ServiceSpaceLifecycleEvent event)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2010. All Rights Reserved.