|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.javasimon.spring.BasicMonitoringInterceptor
public class BasicMonitoringInterceptor
Basic method interceptor that measures the duration of the intercepted call with a Stopwatch.
Class can be overridden in case more sophisticated measuring needs to be provided - this all should
happen in processInvoke(org.aopalliance.intercept.MethodInvocation, org.javasimon.Split) method.
| Field Summary | |
|---|---|
private StopwatchSource<org.aopalliance.intercept.MethodInvocation> |
stopwatchSource
|
| Constructor Summary | |
|---|---|
BasicMonitoringInterceptor()
Default constructor using SimonManager.manager. |
|
BasicMonitoringInterceptor(Manager manager)
Constructor with specified Manager. |
|
BasicMonitoringInterceptor(StopwatchSource<org.aopalliance.intercept.MethodInvocation> stopwatchSource)
Constructor with specified MonitorSource. |
|
| Method Summary | |
|---|---|
Object |
invoke(org.aopalliance.intercept.MethodInvocation invocation)
Performs method invocation and wraps it with Stopwatch. |
protected Object |
processInvoke(org.aopalliance.intercept.MethodInvocation invocation,
Split split)
Method with default invoke (just calls proceed). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private final StopwatchSource<org.aopalliance.intercept.MethodInvocation> stopwatchSource
| Constructor Detail |
|---|
public BasicMonitoringInterceptor(StopwatchSource<org.aopalliance.intercept.MethodInvocation> stopwatchSource)
MonitorSource.
stopwatchSource - stopwatch provider for method invocationpublic BasicMonitoringInterceptor(Manager manager)
Manager.
public BasicMonitoringInterceptor()
SimonManager.manager.
| Method Detail |
|---|
public final Object invoke(org.aopalliance.intercept.MethodInvocation invocation)
throws Throwable
invoke in interface org.aopalliance.intercept.MethodInterceptorinvocation - method invocation
Throwable - anything thrown by the method
protected Object processInvoke(org.aopalliance.intercept.MethodInvocation invocation,
Split split)
throws Throwable
invocation.proceed().
invocation - method invocationsplit - running split for this monitored action
Throwable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||