|
|||||||||
| Home >> All >> org >> activemq >> [ capacity overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.activemq.capacity
Class DelegateCapacityMonitor

java.lang.Objectorg.activemq.capacity.DelegateCapacityMonitor
- All Implemented Interfaces:
- CapacityMonitor
- public class DelegateCapacityMonitor
- extends java.lang.Object
- implements CapacityMonitor
- extends java.lang.Object
BasicCapacityMonitor implementation
- Version:
- $Revision: 1.1.1.1 $
| Nested Class Summary |
| Nested classes inherited from class org.activemq.capacity.CapacityMonitor |
CapacityMonitor.BasicCapacityMonitor |
| Field Summary | |
(package private) CopyOnWriteArrayList |
listeners
|
(package private) CapacityMonitor |
monitor
|
(package private) java.lang.String |
name
|
| Constructor Summary | |
DelegateCapacityMonitor()
Construct a DelegateCapacityMonitor |
|
DelegateCapacityMonitor(java.lang.String name,
CapacityMonitor cm)
Construct a DelegateCapacityMonitor |
|
| Method Summary | |
void |
addCapacityEventListener(CapacityMonitorEventListener l)
Add a CapacityEventListener |
CapacityMonitorEvent |
generateCapacityMonitorEvent()
|
int |
getCurrentCapacity()
Get the current capscity of the service as a percentage |
long |
getCurrentValue()
Get the current value of the CapacityMonitor |
java.lang.String |
getName()
Get the name of the CapacityMonitor |
int |
getRoundedCapacity()
Calculates the capacity rounded down to the rounding factor |
int |
getRoundingFactor()
Get the rounding factor - default is 10 |
long |
getValueLimit()
|
void |
removeCapacityEventListener(CapacityMonitorEventListener l)
Remove a CapacityEventListener |
void |
setCurrentValue(long newCurrentValue)
set the current value of the capacity |
void |
setDelegate(CapacityMonitor cm)
Set the delegated one |
void |
setName(java.lang.String newName)
Set the name of the CapacityMonitor |
void |
setRoundingFactor(int newRoundingFactor)
Set the rounding factor (between 1-100) |
void |
setValueLimit(long newValueLimit)
set a new value limit for the CapacityMonitor |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
name
java.lang.String name
monitor
CapacityMonitor monitor
listeners
CopyOnWriteArrayList listeners
| Constructor Detail |
DelegateCapacityMonitor
public DelegateCapacityMonitor()
- Construct a DelegateCapacityMonitor
DelegateCapacityMonitor
public DelegateCapacityMonitor(java.lang.String name, CapacityMonitor cm)
- Construct a DelegateCapacityMonitor
| Method Detail |
setDelegate
public void setDelegate(CapacityMonitor cm)
- Set the delegated one
getName
public java.lang.String getName()
- Get the name of the CapacityMonitor
- Specified by:
getNamein interfaceCapacityMonitor
setName
public void setName(java.lang.String newName)
- Description copied from interface:
CapacityMonitor - Set the name of the CapacityMonitor
- Specified by:
setNamein interfaceCapacityMonitor
getRoundingFactor
public int getRoundingFactor()
- Get the rounding factor - default is 10
- Specified by:
getRoundingFactorin interfaceCapacityMonitor
setRoundingFactor
public void setRoundingFactor(int newRoundingFactor)
- Set the rounding factor (between 1-100)
- Specified by:
setRoundingFactorin interfaceCapacityMonitor
addCapacityEventListener
public void addCapacityEventListener(CapacityMonitorEventListener l)
- Add a CapacityEventListener
- Specified by:
addCapacityEventListenerin interfaceCapacityMonitor
removeCapacityEventListener
public void removeCapacityEventListener(CapacityMonitorEventListener l)
- Remove a CapacityEventListener
- Specified by:
removeCapacityEventListenerin interfaceCapacityMonitor
getCurrentCapacity
public int getCurrentCapacity()
- Get the current capscity of the service as a percentage
- Specified by:
getCurrentCapacityin interfaceCapacityMonitor
getRoundedCapacity
public int getRoundedCapacity()
- Calculates the capacity rounded down to the rounding factor
- Specified by:
getRoundedCapacityin interfaceCapacityMonitor
getCurrentValue
public long getCurrentValue()
- Get the current value of the CapacityMonitor
- Specified by:
getCurrentValuein interfaceCapacityMonitor
setCurrentValue
public void setCurrentValue(long newCurrentValue)
- set the current value of the capacity
- Specified by:
setCurrentValuein interfaceCapacityMonitor
getValueLimit
public long getValueLimit()
- Specified by:
getValueLimitin interfaceCapacityMonitor
setValueLimit
public void setValueLimit(long newValueLimit)
- set a new value limit for the CapacityMonitor
- Specified by:
setValueLimitin interfaceCapacityMonitor
generateCapacityMonitorEvent
public CapacityMonitorEvent generateCapacityMonitorEvent()
- Specified by:
generateCapacityMonitorEventin interfaceCapacityMonitor
|
|||||||||
| Home >> All >> org >> activemq >> [ capacity overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.activemq.capacity.DelegateCapacityMonitor