|
JSF-Spring | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.context.support.ApplicationObjectSupport org.springframework.web.context.support.WebApplicationObjectSupport org.springframework.web.servlet.support.WebContentGenerator org.springframework.web.servlet.mvc.AbstractController de.mindmatters.faces.spring.context.servlet.controller.AbstractFacesController de.mindmatters.faces.spring.context.servlet.controller.SimpleActionController
public class SimpleActionController
This Controller implements an ActionSource
and fullfills completely
the contract of an ActionSource. So this Controller can be used like a
UICommand
which will be fully configured and mapped in the
FacesDispatcherServlet
's
application context.
For more information please have a look at the UICommand
and
ActionSource
documentations.
Field Summary |
---|
Fields inherited from class org.springframework.web.servlet.support.WebContentGenerator |
---|
METHOD_GET, METHOD_HEAD, METHOD_POST |
Fields inherited from class org.springframework.context.support.ApplicationObjectSupport |
---|
logger |
Constructor Summary | |
---|---|
SimpleActionController()
|
Method Summary | |
---|---|
void |
addActionListener(ActionListener listener)
|
MethodBinding |
getAction()
|
MethodBinding |
getActionListener()
|
ActionListener[] |
getActionListeners()
|
protected ModelAndView |
handleRequestInternal(FacesContext context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
Template method. |
boolean |
isImmediate()
|
protected void |
processAction(FacesContext context,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
ActionEvent event)
Process the request. |
void |
removeActionListener(ActionListener listener)
|
void |
setAction(MethodBinding action)
|
void |
setActionListener(MethodBinding actionListener)
|
void |
setActionListeners(java.util.List actionListeners)
Sets the list of new ActionListener s interested in being
notified when ActionEvent s occur. |
void |
setActionSource(ActionSource actionSource)
Sets the ActionSource implementation this controller should use
as delegate. |
void |
setImmediate(boolean immediate)
|
Methods inherited from class de.mindmatters.faces.spring.context.servlet.controller.AbstractFacesController |
---|
handleRequestInternal |
Methods inherited from class org.springframework.web.servlet.mvc.AbstractController |
---|
handleRequest, isSynchronizeOnSession, setSynchronizeOnSession |
Methods inherited from class org.springframework.web.servlet.support.WebContentGenerator |
---|
applyCacheSeconds, applyCacheSeconds, cacheForSeconds, cacheForSeconds, checkAndPrepare, checkAndPrepare, getCacheSeconds, getSupportedMethods, isRequireSession, isUseCacheControlHeader, isUseExpiresHeader, preventCaching, setCacheSeconds, setRequireSession, setSupportedMethods, setUseCacheControlHeader, setUseExpiresHeader |
Methods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport |
---|
getServletContext, getTempDir, getWebApplicationContext, isContextRequired, setServletContext |
Methods inherited from class org.springframework.context.support.ApplicationObjectSupport |
---|
getApplicationContext, getMessageSourceAccessor, initApplicationContext, requiredContextClass, setApplicationContext |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimpleActionController()
Method Detail |
---|
protected final ModelAndView handleRequestInternal(FacesContext context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
handleRequest
.
handleRequestInternal
in class AbstractFacesController
context
- FacesContext
for the current requestrequest
- current HTTP requestresponse
- current HTTP response
null
if handled
directlyAbstractController.handleRequest(HttpServletRequest,
HttpServletResponse)
protected void processAction(FacesContext context, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, ActionEvent event)
setActionListeners(List)
) are
notified and before the Action and ActionListener MethodBinding
s
of this ActionSource
will be processed. May be overriden in
subclasses.
context
- FacesContext
for the current requestrequest
- current HTTP requestresponse
- current HTTP responseevent
- current ActionEventpublic final void setActionSource(ActionSource actionSource)
ActionSource
implementation this controller should use
as delegate. Default ActionSource is a UICommand
instance.
actionSource
- the ActionSource to use for internal purposes.public final void addActionListener(ActionListener listener)
addActionListener
in interface ActionSource
public final MethodBinding getAction()
getAction
in interface ActionSource
public final MethodBinding getActionListener()
getActionListener
in interface ActionSource
public final ActionListener[] getActionListeners()
getActionListeners
in interface ActionSource
public final boolean isImmediate()
isImmediate
in interface ActionSource
public final void removeActionListener(ActionListener listener)
removeActionListener
in interface ActionSource
public final void setAction(MethodBinding action)
setAction
in interface ActionSource
public final void setActionListener(MethodBinding actionListener)
setActionListener
in interface ActionSource
public final void setImmediate(boolean immediate)
setImmediate
in interface ActionSource
public final void setActionListeners(java.util.List actionListeners)
ActionListener
s interested in being
notified when ActionEvent
s occur.
actionListeners
- the ActionListener
instance to use
|
JSF-Spring | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |