|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.struts2.jsf.FacesSupport
org.apache.struts2.jsf.FacesSetupInterceptor
public class FacesSetupInterceptor
* Initializes the JSF context for this request.
The JSF Application can additionaly be configured from the Struts.xml by adding <param> tags to the jsfSetup <interceptor-ref>.
Example struts.xml configuration:
<interceptor-ref name="jsfSetup"> <param name="actionListener"></param> <param name="defaultRenderKitId"></param> <param name="supportedLocale"></param> <param name="defaultLocale"></param> <param name="messageBundle"></param> <param name="navigationHandler">org.apache.struts2.jsf.StrutsNavigationHandler</param> <param name="propertyResolver"></param> <param name="stateManager"></param> <param name="variableResolver"> org.apache.myfaces.el.VariableResolverImpl ,org.apache.struts2.jsf.StrutsVariableResolver </param> <param name="viewHandler;">org.apache.shale.tiles.TilesViewHandler</param> </interceptor-ref>
Note: None of the parameters are required but all are shown in the example for completeness.
Field Summary |
---|
Fields inherited from class org.apache.struts2.jsf.FacesSupport |
---|
FACES_ENABLED, log |
Constructor Summary | |
---|---|
FacesSetupInterceptor()
|
Method Summary | |
---|---|
void |
destroy()
Cleans up the lifecycle and factories |
void |
init()
Initializes the lifecycle and factories |
java.lang.String |
intercept(ActionInvocation invocation)
Creates the faces context for other phases. |
protected boolean |
isFacesAction(ActionInvocation inv)
Determines if this action mapping will be have a JSF view |
void |
setActionListener(java.lang.String actionListener)
Takes a comma delimited string of class names and stores the names in an ArrayList . |
void |
setDefaultLocale(java.lang.String defaultLocale)
Stores a String representation of the defaultLocale. |
void |
setDefaultRenderKitId(java.lang.String defaultRenderKitId)
A String to be used as the defaultRenderKitId for the jsf
application. |
void |
setLifecycleId(java.lang.String id)
Sets the lifecycle id |
void |
setMessageBundle(java.lang.String messageBundle)
Stores the messageBundle to be used to configure the jsf Application. |
void |
setNavigationHandler(java.lang.String navigationHandlerName)
Takes a comma delimited string of class names and stores the names in an ArrayList . |
void |
setPropertyResolver(java.lang.String propertyResolverName)
Takes a comma delimited string of class names and stores the names in an ArrayList . |
void |
setStateManager(java.lang.String stateManagerName)
Takes a comma delimited string of class names and stores the names in an ArrayList . |
void |
setSupportedLocale(java.lang.String supportedLocale)
Takes a comma delimited string of local names and stores the names in an ArrayList . |
void |
setVariableResolver(java.lang.String variableResolverName)
Takes a comma delimited string of class names and stores the names in an ArrayList . |
void |
setViewHandler(java.lang.String viewHandlerName)
Takes a comma delimited string of class names and stores the names in an ArrayList . |
Methods inherited from class org.apache.struts2.jsf.FacesSupport |
---|
informPhaseListenersAfter, informPhaseListenersBefore, isResponseComplete, setLifecycle, shouldRenderResponse |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FacesSetupInterceptor()
Method Detail |
---|
public void setLifecycleId(java.lang.String id)
id
- The idpublic void init()
init
in interface Interceptor
public java.lang.String intercept(ActionInvocation invocation) throws java.lang.Exception
intercept
in interface Interceptor
invocation
- The action invocation
java.lang.Exception
public void destroy()
destroy
in interface Interceptor
protected boolean isFacesAction(ActionInvocation inv)
inv
- The action invocation
public void setActionListener(java.lang.String actionListener)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
actionListener
- A comma delimited string of class namespublic void setDefaultRenderKitId(java.lang.String defaultRenderKitId)
String
to be used as the defaultRenderKitId for the jsf
application. The incoming String
will be cleaned of
whitespace characters.
defaultRenderKitId
- The defaultRenderKitIdpublic void setSupportedLocale(java.lang.String supportedLocale)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
supportedLocale
- A comma delimited string of local namespublic void setDefaultLocale(java.lang.String defaultLocale)
String
will be cleaned of any whitespace characters before
the class names are stored.
defaultLocale
- The default localpublic void setMessageBundle(java.lang.String messageBundle)
messageBundle
- The messageBundlepublic void setNavigationHandler(java.lang.String navigationHandlerName)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
navigationHandlerName
- A comma delimited string of class namespublic void setPropertyResolver(java.lang.String propertyResolverName)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
propertyResolverName
- A comma delimited string of class namespublic void setStateManager(java.lang.String stateManagerName)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
stateManagerName
- A comma delimited string of class namespublic void setVariableResolver(java.lang.String variableResolverName)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
variableResolverName
- A comma delimited string of class namespublic void setViewHandler(java.lang.String viewHandlerName)
ArrayList
. The incoming String
will be
cleaned of any whitespace characters before the class names are stored.
viewHandlerName
- A comma delimited string of class names
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |