jodd.madvoc.interceptor
Class EchoInterceptor
java.lang.Object
jodd.madvoc.interceptor.ActionInterceptor
jodd.madvoc.interceptor.EchoInterceptor
- Direct Known Subclasses:
- LogEchoInterceptor
public class EchoInterceptor
- extends ActionInterceptor
Simple interceptor that measures time and prints out information about invoked actions.
User may inherit it and change the way message is printed.
|
Method Summary |
java.lang.Object |
intercept(ActionRequest actionRequest)
Measure action invocation time. |
protected void |
out(java.lang.String message)
Outputs info message. |
protected void |
printAfter(ActionRequest request,
long executionTime,
java.lang.Object result)
Prints out the message. |
protected void |
printBefore(ActionRequest request)
Prints out the message. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
EchoInterceptor
public EchoInterceptor()
intercept
public java.lang.Object intercept(ActionRequest actionRequest)
throws java.lang.Exception
- Measure action invocation time.
- Specified by:
intercept in class ActionInterceptor
- Throws:
java.lang.Exception
printBefore
protected void printBefore(ActionRequest request)
- Prints out the message. User can override this method and modify the way
the message is printed.
printAfter
protected void printAfter(ActionRequest request,
long executionTime,
java.lang.Object result)
- Prints out the message. User can override this method and modify the way
the message is printed.
out
protected void out(java.lang.String message)
- Outputs info message. By default, it outputs it to console.
Copyright © 2003-2010 Jodd Team