org.d_haven.mpool

Class ManagePoolsCommand

public class ManagePoolsCommand extends Object implements RepeatedCommand

The ManagePoolsCommand will manage a set of pools using the same set of parameters. These parameters are "good enough" parameters, and are only meant as a starting point. Eventually we will provide a mechanism to customize everything.
Field Summary
static intDEFAULT_MAX
static longDELAY_INTERVAL
intm_grow
intm_max
intm_min
Listm_pools
Constructor Summary
ManagePoolsCommand(List pools)
Create the ManagePoolsCommand with the supplied list of pools.
Method Summary
voidexecute()
longgetDelayInterval()
intgetNumberOfRepeats()
longgetRepeatInterval()
StringtoString()

Field Detail

DEFAULT_MAX

private static final int DEFAULT_MAX

DELAY_INTERVAL

private static final long DELAY_INTERVAL

m_grow

private final int m_grow

m_max

private final int m_max

m_min

private final int m_min

m_pools

private final List m_pools

Constructor Detail

ManagePoolsCommand

public ManagePoolsCommand(List pools)
Create the ManagePoolsCommand with the supplied list of pools. The command will use the list of pools as is so that any additions and removals from the list is handled correctly.

Parameters: pools the list of pools to manage

Method Detail

execute

public void execute()

getDelayInterval

public long getDelayInterval()

getNumberOfRepeats

public int getNumberOfRepeats()

getRepeatInterval

public long getRepeatInterval()

toString

public String toString()