Package com.sun.faces.application.view
Class ViewHandlingStrategyManager
java.lang.Object
com.sun.faces.application.view.ViewHandlingStrategyManager
public class ViewHandlingStrategyManager extends Object
Interface for working with multiple
ViewHandlingStrategy implementations.-
Constructor Summary
Constructors Constructor Description ViewHandlingStrategyManager()Be default, ifWebConfiguration.BooleanWebContextInitParameter.DisableFaceletJSFViewHandlerisn't enabled, the strategies available (in order) will beFaceletViewHandlingStrategyandJspViewHandlingStrategy. -
Method Summary
Modifier and Type Method Description ViewHandlingStrategygetStrategy(String viewId)Iterate through the availableViewHandlingStrategyimplementations.ViewHandlingStrategy[]getViewHandlingStrategies()voidsetViewHandlingStrategies(ViewHandlingStrategy[] stratagies)Update theViewHandlingStrategyimplementations to be applied when processing JSF requests.
-
Constructor Details
-
ViewHandlingStrategyManager
public ViewHandlingStrategyManager()Be default, ifWebConfiguration.BooleanWebContextInitParameter.DisableFaceletJSFViewHandlerisn't enabled, the strategies available (in order) will beFaceletViewHandlingStrategyandJspViewHandlingStrategy.Otherwise, only the
JspViewHandlingStrategywill be available.
-
-
Method Details
-
getStrategy
Iterate through the available
ViewHandlingStrategyimplementations. The first one to return true fromViewHandlingStrategy.handlesViewId(String)will be theViewHandlingStrategyreturned.- Parameters:
viewId- the viewId to match aViewHandlingStrategyto- Returns:
- a
ViewHandlingStrategyfor the specifedviewId - Throws:
ViewHandlingStrategyNotFoundException- if no match is found.
-
getViewHandlingStrategies
- Returns:
- the currently registered
ViewHandlingStrategyimplementations.
-
setViewHandlingStrategies
Update theViewHandlingStrategyimplementations to be applied when processing JSF requests.- Parameters:
stratagies- the new view handling strategies
-