java.lang.Object
org.infohazard.maverick.ctl.FormBeanUser
- All Implemented Interfaces:
- org.infohazard.maverick.flow.Controller, org.infohazard.maverick.flow.ControllerSingleton
- public abstract class FormBeanUser
- extends java.lang.Object
- implements org.infohazard.maverick.flow.ControllerSingleton
FormBeanUser is a base class for singleton controllers which use
external FormBeans rather than populating themselves. Since
only one of these will exist for each command definition,
it must be thread-safe. This Controller pattern is very similar
to Struts Actions.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SUCCESS
public static final java.lang.String SUCCESS
- Common name for the typical "success" view.
- See Also:
- Constant Field Values
ERROR
public static final java.lang.String ERROR
- Common name for the typical "error" view.
- See Also:
- Constant Field Values
FormBeanUser
public FormBeanUser()
init
public void init(org.jdom.Element controllerNode)
throws org.infohazard.maverick.flow.ConfigException
- If you want any custom behavior based on the content of the
configuration file, this will be called once before the
FormBeanUser is ever used.
- Specified by:
init in interface org.infohazard.maverick.flow.ControllerSingleton
go
public final java.lang.String go(org.infohazard.maverick.flow.ControllerContext cctx)
throws javax.servlet.ServletException
- Executes this controller. Override one of the other perform()
methods to provide application logic.
- Specified by:
go in interface org.infohazard.maverick.flow.Controller
perform
protected java.lang.String perform(java.lang.Object formBean,
org.infohazard.maverick.flow.ControllerContext cctx)
throws java.lang.Exception
- This method can be overriden to perform application logic.
Override this method if you want the model to be something
other than the formBean itself.
makeFormBean
protected abstract java.lang.Object makeFormBean(org.infohazard.maverick.flow.ControllerContext cctx)
- This method will be called to produce a simple bean whose properties
will be populated with the http request parameters. The parameters
are useful for doing things like persisting beans across requests.