|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.commons.monitoring.impl.repositories.AbstractRepository
org.apache.commons.monitoring.listeners.SecondaryRepository
public class SecondaryRepository
A repository implementation that registers as a Listener to an Observable repository and maintains a set of Monitors in sync with the observed repository.
As a Detachable implementation, the SecondaryRepository can be detached from the observed repository and used to build a report for the observed period.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.apache.commons.monitoring.Repository |
|---|
Repository.Listener, Repository.Observable |
| Constructor Summary | |
|---|---|
SecondaryRepository(Repository.Observable repository)
|
|
| Method Summary | |
|---|---|
void |
detach()
Detach the instance from live monitoring beackbone. |
long |
getAttachedAt()
|
long |
getDetachedAt()
|
protected Monitor |
getMonitor(Monitor.Key key)
|
boolean |
isDetached()
|
void |
newMonitorInstance(Monitor monitor)
A monitor has just been created. |
StopWatch |
start(Monitor monitor)
Start a StopWatch to monitor execution |
| Methods inherited from class org.apache.commons.monitoring.impl.repositories.AbstractRepository |
|---|
getCategories, getMonitor, getMonitor, getMonitor, getMonitors, getMonitorsFromCategory, getMonitorsFromSubSystem, getSubSystems, register, reset |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SecondaryRepository(Repository.Observable repository)
| Method Detail |
|---|
public void detach()
Detachable
detach in interface Detachableprotected Monitor getMonitor(Monitor.Key key)
getMonitor in class AbstractRepositoryAbstractRepository.getMonitor(org.apache.commons.monitoring.Monitor.Key)public void newMonitorInstance(Monitor monitor)
Repository.Listener
newMonitorInstance in interface Repository.ListenerRepository.Listener.newMonitorInstance(org.apache.commons.monitoring.Monitor)public StopWatch start(Monitor monitor)
start in interface Repositorymonitor - the monitor associated with the process
Repository.start(org.apache.commons.monitoring.Monitor)public long getAttachedAt()
getAttachedAt in interface Detachablepublic long getDetachedAt()
getDetachedAt in interface Detachablepublic boolean isDetached()
isDetached in interface DetachableDetachable.isDetached()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||