jodd.madvoc.interceptor
Class PrepareInterceptor
java.lang.Object
jodd.madvoc.interceptor.ActionInterceptor
jodd.madvoc.interceptor.PrepareInterceptor
public class PrepareInterceptor
- extends ActionInterceptor
Prepares action by calling prepare() before action method invocation.
A typical use of this is to run some logic to load an object from the database, so that when parameters are set
they can be set on this object. For example, suppose you have a User object with two properties: id and name.
Provided that the params interceptor is called twice (once before and once after this interceptor), you can load the
User object using the id property, and then when the second params interceptor is called the parameter user.name will
be set, as desired, on the actual object loaded from the database.
- See Also:
PrepareAndIdInjectorInterceptor
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
PrepareInterceptor
public PrepareInterceptor()
intercept
public java.lang.Object intercept(ActionRequest actionRequest)
throws java.lang.Exception
- Intercepts action requests.
- Specified by:
intercept in class ActionInterceptor
- Throws:
java.lang.Exception
Copyright © 2003-2010 Jodd Team