public class FaceletViewDeclarationLanguage extends FaceletViewDeclarationLanguageBase
| Modifier and Type | Field and Description |
|---|---|
static String |
BUILDING_VIEW_METADATA |
static String |
CACHED_COMPONENT_IDS
Key used to cache component ids for the counter
|
static String |
CHARACTER_ENCODING_KEY |
static String |
CLEAN_TRANSIENT_BUILD_ON_RESTORE |
static String |
DEFAULT_CHARACTER_ENCODING |
static long |
DEFAULT_REFRESH_PERIOD |
static long |
DEFAULT_REFRESH_PERIOD_PRODUCTION |
static String |
FILLED_VIEW |
static String |
IS_BUILDING_INITIAL_STATE_KEY_ALIAS |
static String |
MARK_INITIAL_STATE_KEY
Marker to indicate tag handlers the view currently being built is using
partial state saving and it is necessary to call UIComponent.markInitialState
after component instances are populated.
|
static String |
PARAM_ENCODING
Constant used by EncodingHandler to indicate the current encoding of the page being built,
and indicate which one is the response encoding on getResponseEncoding(FacesContext, String) method.
|
static String |
PARAM_REFRESH_PERIOD_DEPRECATED
Define the period used to refresh the facelet abstract syntax tree from the view definition file.
|
static String |
PARAM_RESOURCE_RESOLVER
Class implementing ResourceResolver interface used to locate facelet resources.
|
static String[] |
PARAMS_REFRESH_PERIOD |
static String |
REFRESH_TRANSIENT_BUILD_ON_PSS |
static String |
REFRESHING_TRANSIENT_BUILD |
static String |
REMOVING_COMPONENTS_BUILD |
static String |
USING_PSS_ON_THIS_VIEW |
FACELETS_VIEW_DECLARATION_LANGUAGE_ID, JSP_VIEW_DECLARATION_LANGUAGE_ID| Constructor and Description |
|---|
FaceletViewDeclarationLanguage(FacesContext context) |
FaceletViewDeclarationLanguage(FacesContext context,
ViewDeclarationLanguageStrategy strategy) |
| Modifier and Type | Method and Description |
|---|---|
static void |
_publishPostBuildComponentTreeOnRestoreViewEvent(FacesContext context,
UIComponent component) |
void |
buildView(FacesContext context,
UIViewRoot view) |
List<String> |
calculateResourceLibraryContracts(FacesContext context,
String viewId) |
protected String |
calculateViewId(FacesContext context,
String viewId) |
static void |
cleanTransientBuildOnRestore(FacesContext context) |
protected Compiler |
createCompiler(FacesContext context)
Creates the Facelet page compiler.
|
UIComponent |
createComponent(FacesContext context,
String taglibURI,
String tagName,
Map<String,Object> attributes) |
protected FaceletFactory |
createFaceletFactory(FacesContext context,
Compiler compiler)
Creates a FaceletFactory instance using the specified compiler.
|
protected ResponseWriter |
createResponseWriter(FacesContext context) |
UIViewRoot |
createView(FacesContext context,
String viewId) |
BeanInfo |
getComponentMetadata(FacesContext context,
Resource componentResource)
retargetMethodExpressions(FacesContext, UIComponent) has some clues about the behavior of this method
|
protected String |
getDefaultSuffix(FacesContext context)
Deprecated.
this code is not used anymore
|
FaceletFactory |
getFaceletFactory() |
protected FaceletsCompilerSupport |
getFaceletsCompilerSupport() |
String |
getId() |
protected String |
getRenderedViewId(FacesContext context,
String actionId)
Deprecated.
|
protected String |
getResponseContentType(FacesContext context,
String orig)
Generate the content type
|
protected String |
getResponseEncoding(FacesContext context,
String orig)
Generate the encoding
|
Resource |
getScriptComponentResource(FacesContext context,
Resource componentResource) |
StateManagementStrategy |
getStateManagementStrategy(FacesContext context,
String viewId) |
ViewMetadata |
getViewMetadata(FacesContext context,
String viewId) |
Stream<String> |
getViews(FacesContext facesContext,
String path,
int maxDepth,
ViewVisitOption... options) |
protected void |
handleFaceletNotFound(FacesContext context,
String viewId) |
protected void |
handleRenderException(FacesContext context,
Exception e) |
protected void |
initialize(FacesContext context)
Initialize the ViewHandler during its first request.
|
static boolean |
isBuildingViewMetadata(FacesContext context)
Check if the current facelet applied is used to build view metadata.
|
static boolean |
isCleanTransientBuildOnRestore(FacesContext context) |
static boolean |
isMarkInitialState(FacesContext context) |
static boolean |
isRefreshingTransientBuild(FacesContext context) |
static boolean |
isRefreshTransientBuildOnPSS(FacesContext context) |
static boolean |
isRefreshTransientBuildOnPSSAuto(FacesContext context) |
static boolean |
isRemovingComponentBuild(FacesContext context) |
static boolean |
isUsingPSSOnThisView(FacesContext context) |
protected void |
loadDecorators(FacesContext context,
Compiler compiler)
Load the various decorators for Facelets.
|
protected void |
loadLibraries(FacesContext context,
Compiler compiler)
Load the various tag libraries for Facelets.
|
protected void |
loadOptions(FacesContext context,
Compiler compiler)
Load the various options for Facelets compiler.
|
void |
renderView(FacesContext context,
UIViewRoot view) |
UIViewRoot |
restoreView(FacesContext context,
String viewId) |
void |
retargetAttachedObjects(FacesContext context,
UIComponent topLevelComponent,
List<AttachedObjectHandler> handlerList)
In short words, this method take care of "target" an "attached object".
|
void |
retargetMethodExpressions(FacesContext context,
UIComponent topLevelComponent) |
protected void |
sendSourceNotFound(FacesContext context,
String message) |
void |
setFaceletsCompilerSupport(FaceletsCompilerSupport support) |
boolean |
viewExists(FacesContext facesContext,
String viewId) |
activateDynamicComponentRefreshTransientBuild, dynamicComponentNeedsRefresh, getRenderKitFactory, getVisitContextFactory, isDynamicComponentNeedsRefresh, isDynamicComponentRefreshTransientBuildActive, isDynamicComponentRefreshTransientBuildActive, resetDynamicComponentNeedsRefreshFlagcheckNullgetViewspublic static final String CHARACTER_ENCODING_KEY
public static final long DEFAULT_REFRESH_PERIOD
public static final long DEFAULT_REFRESH_PERIOD_PRODUCTION
public static final String DEFAULT_CHARACTER_ENCODING
public static final String PARAM_ENCODING
@JSFWebConfigParam(since="2.0",
defaultValue="-1",
deprecated=true)
public static final String PARAM_REFRESH_PERIOD_DEPRECATED
By default is infinite (no active).
public static final String[] PARAMS_REFRESH_PERIOD
@JSFWebConfigParam(since="2.0",
alias="facelets.RESOURCE_RESOLVER")
public static final String PARAM_RESOURCE_RESOLVER
public static final String FILLED_VIEW
public static final String BUILDING_VIEW_METADATA
public static final String REFRESHING_TRANSIENT_BUILD
public static final String REFRESH_TRANSIENT_BUILD_ON_PSS
public static final String USING_PSS_ON_THIS_VIEW
public static final String REMOVING_COMPONENTS_BUILD
public static final String MARK_INITIAL_STATE_KEY
public static final String IS_BUILDING_INITIAL_STATE_KEY_ALIAS
public static final String CLEAN_TRANSIENT_BUILD_ON_RESTORE
public static final String CACHED_COMPONENT_IDS
public FaceletViewDeclarationLanguage(FacesContext context)
public FaceletViewDeclarationLanguage(FacesContext context, ViewDeclarationLanguageStrategy strategy)
public String getId()
getId in class ViewDeclarationLanguagepublic boolean viewExists(FacesContext facesContext, String viewId)
viewExists in class ViewDeclarationLanguagepublic void buildView(FacesContext context, UIViewRoot view) throws IOException
buildView in class ViewDeclarationLanguageIOExceptionpublic static void _publishPostBuildComponentTreeOnRestoreViewEvent(FacesContext context, UIComponent component)
public BeanInfo getComponentMetadata(FacesContext context, Resource componentResource)
getComponentMetadata in class ViewDeclarationLanguagepublic static boolean isBuildingViewMetadata(FacesContext context)
context - public static boolean isRefreshingTransientBuild(FacesContext context)
public static boolean isRemovingComponentBuild(FacesContext context)
public static boolean isMarkInitialState(FacesContext context)
public static boolean isRefreshTransientBuildOnPSS(FacesContext context)
public static boolean isRefreshTransientBuildOnPSSAuto(FacesContext context)
public static boolean isCleanTransientBuildOnRestore(FacesContext context)
public static void cleanTransientBuildOnRestore(FacesContext context)
public static boolean isUsingPSSOnThisView(FacesContext context)
public void retargetAttachedObjects(FacesContext context, UIComponent topLevelComponent, List<AttachedObjectHandler> handlerList)
retargetAttachedObjects in class ViewDeclarationLanguagepublic void retargetMethodExpressions(FacesContext context, UIComponent topLevelComponent)
retargetMethodExpressions in class ViewDeclarationLanguagepublic Resource getScriptComponentResource(FacesContext context, Resource componentResource)
getScriptComponentResource in class ViewDeclarationLanguagepublic StateManagementStrategy getStateManagementStrategy(FacesContext context, String viewId)
getStateManagementStrategy in class ViewDeclarationLanguagepublic ViewMetadata getViewMetadata(FacesContext context, String viewId)
getViewMetadata in class ViewDeclarationLanguagepublic void renderView(FacesContext context, UIViewRoot view) throws IOException
renderView in class ViewDeclarationLanguageIOExceptionpublic UIViewRoot createView(FacesContext context, String viewId)
createView in class ViewDeclarationLanguageBasepublic UIViewRoot restoreView(FacesContext context, String viewId)
restoreView in class ViewDeclarationLanguageBaseprotected String calculateViewId(FacesContext context, String viewId)
calculateViewId in class ViewDeclarationLanguageBaseprotected Compiler createCompiler(FacesContext context)
context - the current FacesContextprotected FaceletFactory createFaceletFactory(FacesContext context, Compiler compiler)
context - the current FacesContextcompiler - the compiler to be used by the factoryprotected ResponseWriter createResponseWriter(FacesContext context) throws IOException, FacesException
IOExceptionFacesException@Deprecated protected String getDefaultSuffix(FacesContext context) throws FacesException
FacesException@Deprecated protected String getRenderedViewId(FacesContext context, String actionId)
protected String getResponseContentType(FacesContext context, String orig)
context - orig - protected String getResponseEncoding(FacesContext context, String orig)
context - orig - protected void handleFaceletNotFound(FacesContext context, String viewId) throws FacesException, IOException
FacesExceptionIOExceptionprotected void handleRenderException(FacesContext context, Exception e) throws IOException, jakarta.el.ELException, FacesException
IOExceptionjakarta.el.ELExceptionFacesExceptionprotected void initialize(FacesContext context)
protected void loadDecorators(FacesContext context, Compiler compiler)
context - the current FacesContextcompiler - the page compilerprotected FaceletsCompilerSupport getFaceletsCompilerSupport()
public void setFaceletsCompilerSupport(FaceletsCompilerSupport support)
protected void loadLibraries(FacesContext context, Compiler compiler)
context - the current FacesContextcompiler - the page compilerprotected void loadOptions(FacesContext context, Compiler compiler)
context - the current FacesContextcompiler - the page compilerprotected void sendSourceNotFound(FacesContext context, String message)
sendSourceNotFound in class ViewDeclarationLanguageBasepublic List<String> calculateResourceLibraryContracts(FacesContext context, String viewId)
calculateResourceLibraryContracts in class ViewDeclarationLanguagepublic FaceletFactory getFaceletFactory()
public UIComponent createComponent(FacesContext context, String taglibURI, String tagName, Map<String,Object> attributes)
createComponent in class ViewDeclarationLanguagepublic Stream<String> getViews(FacesContext facesContext, String path, int maxDepth, ViewVisitOption... options)
getViews in class ViewDeclarationLanguageCopyright © 2022 The Apache Software Foundation. All rights reserved.