org.riotfamily.forms.controller
Class AjaxFormController

java.lang.Object
  extended by org.riotfamily.forms.controller.AbstractFormController
      extended by org.riotfamily.forms.controller.AjaxFormController
All Implemented Interfaces:
MessageSourceAware, Controller
Direct Known Subclasses:
ChangePasswordController, DialogFormController, RepositoryFormController

public abstract class AjaxFormController
extends AbstractFormController
implements MessageSourceAware


Field Summary
 
Fields inherited from class org.riotfamily.forms.controller.AbstractFormController
BUTTON_CONTAINER_ID, FORM_SUBMISSION_HANDLER, log
 
Constructor Summary
AjaxFormController()
           
 
Method Summary
protected  ModelAndView handleFormRequest(Form form, HttpServletRequest request, HttpServletResponse response)
           
protected  void initForm(Form form, HttpServletRequest request)
          Subclasses may overwrite this method to initialize forms after they have been populated.
protected  boolean isEventRequest(HttpServletRequest request)
           
protected  boolean isInitialRequest(HttpServletRequest request)
          Returns whether the given request is an initial form request.
protected  void processAjaxRequest(Form form, HttpServletRequest request, HttpServletResponse response)
           
protected  void processEventRequest(Form form, HttpServletRequest request)
           
protected  void renderForm(Form form, PrintWriter writer)
           
 void setMessageSource(MessageSource messageSource)
           
 
Methods inherited from class org.riotfamily.forms.controller.AbstractFormController
createAndInitForm, createForm, createModelAndView, getForm, getFormBackingObject, getSessionAttribute, getWriter, handleContentRequest, handleFormSubmission, handleRequest, initController, isContentRequest, isExclusiveRequest, populateForm, processForm, removeFormFromSession, setFormContextFactory, setProcessNewForms, showForm
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AjaxFormController

public AjaxFormController()
Method Detail

setMessageSource

public void setMessageSource(MessageSource messageSource)
Specified by:
setMessageSource in interface MessageSourceAware

handleFormRequest

protected ModelAndView handleFormRequest(Form form,
                                         HttpServletRequest request,
                                         HttpServletResponse response)
                                  throws Exception
Overrides:
handleFormRequest in class AbstractFormController
Throws:
Exception

initForm

protected void initForm(Form form,
                        HttpServletRequest request)
Description copied from class: AbstractFormController
Subclasses may overwrite this method to initialize forms after they have been populated. The default implementation does nothing.

Overrides:
initForm in class AbstractFormController

isEventRequest

protected boolean isEventRequest(HttpServletRequest request)

isInitialRequest

protected boolean isInitialRequest(HttpServletRequest request)
Returns whether the given request is an initial form request.

Overrides:
isInitialRequest in class AbstractFormController

processAjaxRequest

protected void processAjaxRequest(Form form,
                                  HttpServletRequest request,
                                  HttpServletResponse response)
                           throws IOException
Throws:
IOException

processEventRequest

protected void processEventRequest(Form form,
                                   HttpServletRequest request)

renderForm

protected void renderForm(Form form,
                          PrintWriter writer)
Overrides:
renderForm in class AbstractFormController