org.codehaus.wadi.gridstate.impl
Class StaticPartitionManager

java.lang.Object
  extended byorg.codehaus.wadi.gridstate.impl.StaticPartitionManager
All Implemented Interfaces:
PartitionConfig, PartitionManager

public class StaticPartitionManager
extends Object
implements PartitionManager


Field Summary
protected  Dispatcher _dispatcher
           
protected static Log _log
           
protected  PartitionMapper _mapper
           
protected  PartitionFacade[] _partitions
           
 
Constructor Summary
StaticPartitionManager(Dispatcher dispatcher, int numPartitions, PartitionMapper mapper)
           
 
Method Summary
 void evacuate()
           
 Dispatcher getDispatcher()
           
 Destination getLocalDestination()
           
 int getNumPartitions()
           
 PartitionFacade getPartition(Object key)
           
 PartitionFacade[] getPartitions()
           
 void init(PartitionManagerConfig config)
           
static void partition(GCache[] caches, PartitionManager[] managers, int numPartitions)
           
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_dispatcher

protected final Dispatcher _dispatcher

_partitions

protected final PartitionFacade[] _partitions

_mapper

protected final PartitionMapper _mapper

_log

protected static final Log _log
Constructor Detail

StaticPartitionManager

public StaticPartitionManager(Dispatcher dispatcher,
                              int numPartitions,
                              PartitionMapper mapper)
Method Detail

init

public void init(PartitionManagerConfig config)
Specified by:
init in interface PartitionManager

getPartitions

public PartitionFacade[] getPartitions()
Specified by:
getPartitions in interface PartitionManager

getNumPartitions

public int getNumPartitions()
Specified by:
getNumPartitions in interface PartitionManager

partition

public static void partition(GCache[] caches,
                             PartitionManager[] managers,
                             int numPartitions)

getPartition

public PartitionFacade getPartition(Object key)
Specified by:
getPartition in interface PartitionManager

start

public void start()
           throws Exception
Specified by:
start in interface PartitionManager
Throws:
Exception

stop

public void stop()
          throws Exception
Specified by:
stop in interface PartitionManager
Throws:
Exception

getDispatcher

public Dispatcher getDispatcher()
Specified by:
getDispatcher in interface PartitionConfig

getLocalDestination

public Destination getLocalDestination()
Specified by:
getLocalDestination in interface PartitionConfig

evacuate

public void evacuate()
Specified by:
evacuate in interface PartitionManager


Copyright © 2004-2006 Core Developers Network Ltd.. All Rights Reserved.