API Overview API Index Package Overview Direct link to this page
JavaOnTracks 0.1.2
  net.jot.web.ctrl. JOTController View Source
Author(s)
thibautc
Since
Version
Serial
Hierarchy
 Object
      JOTController
Implements
Subclasses
Description
publicabstract abstract class JOTController
  Extends this generic class to implement a Controller The Controller is here to process a request (do the logic required to process it) It gives you easy access to the following objects: request,response,session.
See also:   
Constructors
protected JOTController ()
Methods
Hide/Show inherited methods
protected JOTDataHolder getDataHolder ()
public JOTForm getForm (Class formClass)
  use this method to get/create a form object Will provide either : - a new form object if this form is newly used - the existing form if used earlier in this request (ie: validation failed) This allows you to get the form and put it in the View, or to populate/validate it in your controller.
public JOTMasterController getMaster ()
public void init (JOTMasterController master)
  Will be called by the mastercontroller.
publicabstract String process () throws Exception
  This is the implementaion of the "meat" of your controller, where the controller does it's stuff (logic) That should return a result code, either a standard one.
publicabstract boolean validatePermissions ()
  Implements this to check wether the user is allowed to use your controller.
Fields
Hide/Show inherited fields
public FilterChain filterChain
Gives you easy acess to filterChain should you need it
public FilterConfig filterConfig
Gives you easy acess to filterConfig should you need it
public JOTFlowRequest request
Gives you easy access to the request
public HttpServletResponse response
Gives you easy access to the Response
publicfinalstatic String RESULT_COMPLETED = "completed"
Special return code used for for a controller that will be called many times until ity his considered "completed" For example the Filemanager where you can browse around until you pick a file(completed)
publicfinalstatic String RESULT_FAILURE = "failure"
Return this if the controller failed (Exception/error etc...)
publicfinalstatic String RESULT_FORBIDDEN = "forbidden"
Special return code used when a user calls a controller he has no permission to.
publicfinalstatic String RESULT_SUCCESS = "success"
Return this if the controller processed succesfully (generic success message)
publicfinalstatic String RESULT_VALIDATION_FAILURE = "validation_failure"
Special return code used for Forms(JOTForm), if the form data validation failed.
public HttpSession session
Gives you easy acess to the "Session" object
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.5     ©Thibaut Colar