public abstract class MonitoringComponentAdapter extends java.lang.Object implements ComponentAdapter, ComponentMonitorStrategy, java.io.Serializable
ComponentAdapter
supporting a
ComponentMonitorStrategy
.
It provides a default ComponentMonitor
,
but does not allow to use null
for the component monitor.ComponentAdapter
,
ComponentMonitorStrategy
,
Serialized FormModifier and Type | Field and Description |
---|---|
private ComponentMonitor |
componentMonitor |
Modifier | Constructor and Description |
---|---|
protected |
MonitoringComponentAdapter()
Constructs a MonitoringComponentAdapter with a
default monitor . |
protected |
MonitoringComponentAdapter(ComponentMonitor monitor)
Constructs a MonitoringComponentAdapter with a custom monitor
|
Modifier and Type | Method and Description |
---|---|
void |
changeMonitor(ComponentMonitor monitor)
Changes the component monitor used
|
ComponentMonitor |
currentMonitor()
Returns the monitor currently used
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
accept, getComponentImplementation, getComponentInstance, getComponentKey, verify
private ComponentMonitor componentMonitor
protected MonitoringComponentAdapter(ComponentMonitor monitor)
monitor
- the component monitor used by this ComponentAdapterprotected MonitoringComponentAdapter()
default monitor
.public void changeMonitor(ComponentMonitor monitor)
ComponentMonitorStrategy
changeMonitor
in interface ComponentMonitorStrategy
monitor
- the new ComponentMonitor to usepublic ComponentMonitor currentMonitor()
currentMonitor
in interface ComponentMonitorStrategy