|
|||||||||
| 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 |
String |
intercept(com.opensymphony.xwork2.ActionInvocation invocation)
Creates the faces context for other phases. |
protected boolean |
isFacesAction(com.opensymphony.xwork2.ActionInvocation inv)
Determines if this action mapping will be have a JSF view |
void |
setActionListener(String actionListener)
Takes a comma delimited string of class names and stores the names in an ArrayList. |
void |
setDefaultLocale(String defaultLocale)
Stores a String representation of the defaultLocale. |
void |
setDefaultRenderKitId(String defaultRenderKitId)
A String to be used as the defaultRenderKitId for the jsf
application. |
void |
setLifecycleId(String id)
Sets the lifecycle id |
void |
setMessageBundle(String messageBundle)
Stores the messageBundle to be used to configure the jsf Application. |
void |
setNavigationHandler(String navigationHandlerName)
Takes a comma delimited string of class names and stores the names in an ArrayList. |
void |
setPropertyResolver(String propertyResolverName)
Takes a comma delimited string of class names and stores the names in an ArrayList. |
void |
setStateManager(String stateManagerName)
Takes a comma delimited string of class names and stores the names in an ArrayList. |
void |
setSupportedLocale(String supportedLocale)
Takes a comma delimited string of local names and stores the names in an ArrayList. |
void |
setVariableResolver(String variableResolverName)
Takes a comma delimited string of class names and stores the names in an ArrayList. |
void |
setViewHandler(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(String id)
id - The idpublic void init()
init in interface com.opensymphony.xwork2.interceptor.Interceptor
public String intercept(com.opensymphony.xwork2.ActionInvocation invocation)
throws Exception
intercept in interface com.opensymphony.xwork2.interceptor.Interceptorinvocation - The action invocation
Exceptionpublic void destroy()
destroy in interface com.opensymphony.xwork2.interceptor.Interceptorprotected boolean isFacesAction(com.opensymphony.xwork2.ActionInvocation inv)
inv - The action invocation
public void setActionListener(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(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(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(String defaultLocale)
String will be cleaned of any whitespace characters before
the class names are stored.
defaultLocale - The default localpublic void setMessageBundle(String messageBundle)
messageBundle - The messageBundlepublic void setNavigationHandler(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(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(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(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(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 | ||||||||