Class ApplicationWrapper
- java.lang.Object
-
- jakarta.faces.application.Application
-
- jakarta.faces.application.ApplicationWrapper
-
- All Implemented Interfaces:
FacesWrapper<Application>
public abstract class ApplicationWrapper extends Application implements FacesWrapper<Application>
- Since:
- 2.0
-
-
Constructor Summary
Constructors Constructor Description ApplicationWrapper()
Deprecated.ApplicationWrapper(Application delegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addBehavior(String behaviorId, String behaviorClass)
void
addComponent(String componentType, String componentClass)
Register a new mapping of component type to the name of the correspondingUIComponent
class.void
addConverter(Class<?> targetClass, String converterClass)
Register a new converter class that is capable of performing conversions for the specified target class.void
addConverter(String converterId, String converterClass)
Register a new mapping of converter id to the name of the correspondingConverter
class.void
addDefaultValidatorId(String validatorId)
void
addELContextListener(jakarta.el.ELContextListener listener)
Provide a way for Faces applications to register anELContextListener
that will be notified on creation ofELContext
instances.void
addELResolver(jakarta.el.ELResolver resolver)
Cause an the argumentresolver
to be added to the resolver chain as specified in section 5.5.1 of the JavaServer Faces Specification.void
addSearchKeywordResolver(SearchKeywordResolver resolver)
void
addValidator(String validatorId, String validatorClass)
Register a new mapping of validator id to the name of the correspondingValidator
class.Behavior
createBehavior(String behaviorId)
UIComponent
createComponent(jakarta.el.ValueExpression componentExpression, FacesContext contexte, String componentType)
Call thegetValue()
method on the specifiedValueExpression
.UIComponent
createComponent(jakarta.el.ValueExpression componentExpression, FacesContext context, String componentType, String rendererType)
UIComponent
createComponent(FacesContext context, Resource componentResource)
???UIComponent
createComponent(FacesContext context, String componentType, String rendererType)
UIComponent
createComponent(String componentType)
Create a new UIComponent subclass, using the mappings defined by previous calls to the addComponent method of this class.Converter
createConverter(Class<?> targetClass)
Instantiate and return a new
instance of the class that has registered itself as capable of performing conversions for objects of the specified type.Converter
Converter
createConverter(String converterId)
Instantiate and return a new
instance of the class specified by a previous call toConverter
addConverter()
for the specified converter id.Validator
createValidator(String validatorId)
Instantiate and return a new
instance of the class specified by a previous call toValidator
addValidator()
for the specified validator id.<T> T
evaluateExpressionGet(FacesContext context, String expression, Class<? extends T> expectedType)
Get a value by evaluating an expression.ActionListener
getActionListener()
Return the defaultActionListener
to be registered for allActionSource
components in this appication.Iterator<String>
getBehaviorIds()
Iterator<String>
getComponentTypes()
Return anIterator
over the set of currently defined component types for thisApplication
.Iterator<String>
getConverterIds()
Return anIterator
over the set of currently registered converter ids for thisApplication
Iterator<Class<?>>
getConverterTypes()
Return anIterator
over the set ofClass
instances for whichConverter
classes
have been explicitly registered.Locale
getDefaultLocale()
Return the defaultLocale
for this application.String
getDefaultRenderKitId()
Return therenderKitId
to be used for rendering this application.Map<String,String>
getDefaultValidatorInfo()
jakarta.el.ELContextListener[]
getELContextListeners()
If no calls have been made toaddELContextListener(jakarta.el.ELContextListener)
, this method must return an empty arrayjakarta.el.ELResolver
getELResolver()
Return the singletonELResolver
instance to be used for all EL resolution.jakarta.el.ExpressionFactory
getExpressionFactory()
Return theExpressionFactory
instance for this application.FlowHandler
getFlowHandler()
String
getMessageBundle()
Return the fully qualified class name of theResourceBundle
to be used for JavaServer Faces messages for this application.NavigationHandler
getNavigationHandler()
Return the
instance that will be passed the outcome returned by any invoked application action for this web application.NavigationHandler
ProjectStage
getProjectStage()
Return the project stage for the currently running application instance.ResourceBundle
getResourceBundle(FacesContext ctx, String name)
Find aResourceBundle
as defined in the application configuration resources under the specified name.ResourceHandler
getResourceHandler()
Return the singleton, stateless, thread-safe
for this application.ResourceHandler
SearchExpressionHandler
getSearchExpressionHandler()
SearchKeywordResolver
getSearchKeywordResolver()
StateManager
getStateManager()
Return theStateManager
instance that will be utilized during the Restore View and Render Response phases of the request processing lifecycle.Iterator<Locale>
getSupportedLocales()
Return anIterator
over the supportedLocales
for this appication.Iterator<String>
getValidatorIds()
Return anIterator
over the set of currently registered validator ids for thisApplication
.ViewHandler
getViewHandler()
Set the
instance that will be utilized during theViewHandler
Restore View and Render Response
phases of the request processing lifecycle.Application
getWrapped()
A class that implements this interface uses this method to return an instance of the class being wrapped.void
publishEvent(FacesContext facesContext, Class<? extends SystemEvent> systemEventClass, Class<?> sourceBaseType, Object source)
void
publishEvent(FacesContext facesContext, Class<? extends SystemEvent> systemEventClass, Object source)
If there are one or more listeners for events of the type represented bysystemEventClass
, call those listeners,passing source as thesource
of the event.void
removeELContextListener(jakarta.el.ELContextListener listener)
Remove the argumentlistener
from the list ofELContextListeners
.void
setActionListener(ActionListener listener)
Set the default
to be registered for allActionListener
components.ActionSource
void
setDefaultLocale(Locale locale)
Set the defaultLocale
for this application.void
setDefaultRenderKitId(String renderKitId)
Return therenderKitId
to be used for rendering this application.void
setFlowHandler(FlowHandler flowHandler)
void
setMessageBundle(String bundle)
Set the fully qualified class name of theResourceBundle
to be used for JavaServer Faces messages for this application.void
setNavigationHandler(NavigationHandler handler)
Set theNavigationHandler
instance that will be passed the outcome returned by any invoked application action for this web application.void
setResourceHandler(ResourceHandler resourceHandler)
void
setSearchExpressionHandler(SearchExpressionHandler searchExpressionHandler)
void
setStateManager(StateManager manager)
Set theStateManager
instance that will be utilized during theRestore View and Render Response
phases of the request processing lifecycle.void
setSupportedLocales(Collection<Locale> locales)
Set theLocale
instances representing the supportedLocales
for this application.void
setViewHandler(ViewHandler handler)
Set theViewHandler
instance that will be utilized during theRestore View and Render Response
phases of the request processing lifecycle.void
subscribeToEvent(Class<? extends SystemEvent> systemEventClass, SystemEventListener listener)
void
subscribeToEvent(Class<? extends SystemEvent> systemEventClass, Class<?> sourceClass, SystemEventListener listener)
void
unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass, SystemEventListener listener)
void
unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass, Class<?> sourceClass, SystemEventListener listener)
-
-
-
Constructor Detail
-
ApplicationWrapper
@Deprecated public ApplicationWrapper()
Deprecated.
-
ApplicationWrapper
public ApplicationWrapper(Application delegate)
-
-
Method Detail
-
addBehavior
public void addBehavior(String behaviorId, String behaviorClass)
- Overrides:
addBehavior
in classApplication
-
addComponent
public void addComponent(String componentType, String componentClass)
Description copied from class:Application
Register a new mapping of component type to the name of the correspondingUIComponent
class. This allows subsequent calls tocreateComponent()
to serve as a factory forUIComponent
instances.- Specified by:
addComponent
in classApplication
- Parameters:
componentType
- - The component type to be registeredcomponentClass
- - The fully qualified class name of the correspondingUIComponent
implementation
-
addConverter
public void addConverter(Class<?> targetClass, String converterClass)
Description copied from class:Application
Register a new converter class that is capable of performing conversions for the specified target class.- Specified by:
addConverter
in classApplication
- Parameters:
targetClass
- - The class for which this converter is registeredconverterClass
- - The fully qualified class name of the correspondingConverter
implementation
-
addConverter
public void addConverter(String converterId, String converterClass)
Description copied from class:Application
Register a new mapping of converter id to the name of the correspondingConverter
class. This allows subsequent calls to createConverter() to serve as a factory forConverter
instances.- Specified by:
addConverter
in classApplication
- Parameters:
converterId
- - The converterId to be registeredconverterClass
- - The fully qualified class name of the correspondingConverter
implementation
-
addDefaultValidatorId
public void addDefaultValidatorId(String validatorId)
- Overrides:
addDefaultValidatorId
in classApplication
-
addELContextListener
public void addELContextListener(jakarta.el.ELContextListener listener)
Description copied from class:Application
Provide a way for Faces applications to register an
ELContextListener
that will be notified on creation ofELContext
instances.An implementation is provided that throws
UnsupportedOperationException
so that users that decorate theApplication
continue to work.- Overrides:
addELContextListener
in classApplication
-
addELResolver
public void addELResolver(jakarta.el.ELResolver resolver)
Description copied from class:Application
Cause an the argument
resolver
to be added to the resolver chain as specified in section 5.5.1 of the JavaServer Faces Specification.It is not possible to remove an
ELResolver
registered with this method, once it has been registered.It is illegal to register an ELResolver after the application has received any requests from the client. If an attempt is made to register a listener after that time, an IllegalStateException must be thrown.
ELResolvers
are in the chain, aside from the standard ones. It is permissible to addELResolvers
before or after initialization to a CompositeELResolver that is already in the chain.The default implementation throws
UnsupportedOperationException
and is provided for the sole purpose of not breaking existing applications that extendApplication
.- Overrides:
addELResolver
in classApplication
-
addValidator
public void addValidator(String validatorId, String validatorClass)
Description copied from class:Application
Register a new mapping of validator id to the name of the correspondingValidator
class. This allows subsequent calls tocreateValidator()
to serve as a factory forValidator
instances.- Specified by:
addValidator
in classApplication
- Parameters:
validatorId
- The validator id to be registeredvalidatorClass
- The fully qualified class name of the corresponding Validator implementation
-
createBehavior
public Behavior createBehavior(String behaviorId) throws FacesException
- Overrides:
createBehavior
in classApplication
- Returns:
- Throws:
FacesException
-
createComponent
public UIComponent createComponent(FacesContext context, Resource componentResource)
Description copied from class:Application
???- Overrides:
createComponent
in classApplication
- Returns:
-
createComponent
public UIComponent createComponent(FacesContext context, String componentType, String rendererType)
- Overrides:
createComponent
in classApplication
- Returns:
-
createComponent
public UIComponent createComponent(String componentType) throws FacesException
Description copied from class:Application
Create a new UIComponent subclass, using the mappings defined by previous calls to the addComponent method of this class.
- Specified by:
createComponent
in classApplication
- Throws:
FacesException
- if there is no mapping defined for the specified componentType, or if an instance of the specified type could not be created for any reason.
-
createComponent
public UIComponent createComponent(jakarta.el.ValueExpression componentExpression, FacesContext context, String componentType, String rendererType)
- Overrides:
createComponent
in classApplication
- Returns:
-
createComponent
public UIComponent createComponent(jakarta.el.ValueExpression componentExpression, FacesContext contexte, String componentType) throws FacesException
Description copied from class:Application
Call the
getValue()
method on the specifiedValueExpression
. If it returns a
instance, return it as the value of this method. If it does not, instantiate a newUIComponent
instance of the specified component type, pass the new component to theUIComponent
setValue()
method of the specifiedValueExpression
, and return it.- Overrides:
createComponent
in classApplication
- Parameters:
componentExpression
- -ValueExpression
representing a component value expression (typically specified by thecomponent
attribute of a custom tag)contexte
- -FacesContext
for the current requestcomponentType
- - Component type to create if the ValueExpression does not return a component instance- Throws:
FacesException
- if a
cannot be createdUIComponent
-
createConverter
public Converter createConverter(Class<?> targetClass)
Description copied from class:Application
Instantiate and return a new
instance of the class that has registered itself as capable of performing conversions for objects of the specified type. If no suchConverter
class can be identified, return null.Converter
To locate an appropriate
class, the following algorithm is performed, stopping as soon as an appropriateConverter
class is found: Locate aConverter
registered for the target class itself. Locate aConverter
registered for interfaces that are implemented by the target class (directly or indirectly). Locate aConverter
registered for the superclass (if any) of the target class, recursively working up the inheritance hierarchy.Converter
If the
has a single argument constructor that accepts a Class, instantiate theConverter
using that constructor, passing the argumentConverter
targetClass
as the sole argument. Otherwise, simply use the zero-argument constructor.- Specified by:
createConverter
in classApplication
- Parameters:
targetClass
- - Target class for which to return aConverter
-
createConverter
public Converter createConverter(String converterId)
Description copied from class:Application
Instantiate and return a new
instance of the class specified by a previous call toConverter
addConverter()
for the specified converter id. If there is no such registration for this converter id, returnnull
.- Specified by:
createConverter
in classApplication
- Parameters:
converterId
- - The converter id for which to create and return a new
instanceConverter
-
createValidator
public Validator createValidator(String validatorId) throws FacesException
Description copied from class:Application
Instantiate and return a new
instance of the class specified by a previous call toValidator
addValidator()
for the specified validator id.- Specified by:
createValidator
in classApplication
- Parameters:
validatorId
- The
id for which to create and return a new Validator instanceValidator
- Throws:
FacesException
- if a
of the specified id cannot be createdValidator
-
evaluateExpressionGet
public <T> T evaluateExpressionGet(FacesContext context, String expression, Class<? extends T> expectedType) throws jakarta.el.ELException
Description copied from class:Application
Get a value by evaluating an expression.
Call
then callApplication.getExpressionFactory()
ExpressionFactory.createValueExpression(jakarta.el.ELContext, java.lang.String, java.lang.Class)
passing the argumentexpression
andexpectedType
. Call
and pass it toFacesContext.getELContext()
ValueExpression.getValue(jakarta.el.ELContext)
, returning the result.An implementation is provided that throws
UnsupportedOperationException
so that users that decorate theApplication
continue to work.- Overrides:
evaluateExpressionGet
in classApplication
- Throws:
jakarta.el.ELException
-
getActionListener
public ActionListener getActionListener()
Description copied from class:Application
Return the default
ActionListener
to be registered for allActionSource
components in this appication. If not explicitly set, a default implementation must be provided that performs the following functions:- The
processAction()
method must first callFacesContext.renderResponse()
in order to bypass any intervening lifecycle phases, once the method returns. - The
processAction()
method must next determine the logical outcome of this event, as follows: - If the originating component has a non-
null action
property, retrieve theMethodExpression
from the property, and callinvoke()
on it. Convert the returned value (if any) to a String, and use it as the logical outcome. - Otherwise, the logical outcome is null.
- The
processAction()
method must finally retrieve theNavigationHandler
instance for this application and callNavigationHandler.handleNavigation(jakarta.faces.context.FacesContext, java.lang.String, java.lang.String)
passing: - the
FacesContext
for the current request - If there is a
MethodExpression
instance for theaction
property of this component, the result of callingExpression.getExpressionString()
on it, null otherwise - the logical outcome as determined above
Note that the specification for the default
ActionListener
contiues to call for the use of a deprecated property (action
) and class (MethodExpression
). Unfortunately, this is necessary because the default ActionListener must continue to work with components that do not implementActionSource2
, and only implementActionSource
.- Specified by:
getActionListener
in classApplication
- The
-
getBehaviorIds
public Iterator<String> getBehaviorIds()
- Overrides:
getBehaviorIds
in classApplication
- Returns:
-
getComponentTypes
public Iterator<String> getComponentTypes()
Description copied from class:Application
Return anIterator
over the set of currently defined component types for thisApplication
.- Specified by:
getComponentTypes
in classApplication
-
getConverterIds
public Iterator<String> getConverterIds()
Description copied from class:Application
Return anIterator
over the set of currently registered converter ids for thisApplication
- Specified by:
getConverterIds
in classApplication
- Returns:
-
getConverterTypes
public Iterator<Class<?>> getConverterTypes()
Description copied from class:Application
Return anIterator
over the set ofClass
instances for whichConverter
classes
have been explicitly registered.- Specified by:
getConverterTypes
in classApplication
- Returns:
-
getDefaultLocale
public Locale getDefaultLocale()
Description copied from class:Application
Return the defaultLocale
for this application. If not explicitly set,null
is returned.- Specified by:
getDefaultLocale
in classApplication
- Returns:
-
getDefaultRenderKitId
public String getDefaultRenderKitId()
Description copied from class:Application
Return therenderKitId
to be used for rendering this application. If not explicitly set,null
is returned.- Specified by:
getDefaultRenderKitId
in classApplication
- Returns:
-
getDefaultValidatorInfo
public Map<String,String> getDefaultValidatorInfo()
- Overrides:
getDefaultValidatorInfo
in classApplication
- Returns:
-
getELContextListeners
public jakarta.el.ELContextListener[] getELContextListeners()
Description copied from class:Application
If no calls have been made to
addELContextListener(jakarta.el.ELContextListener)
, this method must return an empty array.
Otherwise, return an array representing the list of listeners added by calls to
addELContextListener(jakarta.el.ELContextListener)
.An
implementation
is provided that throws UnsupportedOperationException so that users that decorate theApplication
continue to work.- Overrides:
getELContextListeners
in classApplication
-
getELResolver
public jakarta.el.ELResolver getELResolver()
Description copied from class:Application
Return the singletonELResolver
instance to be used for all EL resolution. This is actually an instance ofCompositeELResolver
that must contain the following ELResolver instances in the following order:ELResolver
instances declared using the <el-resolver> element in the application configuration resources.- An
implementation
that wraps the head of the legacy VariableResolver chain, as per sectionVariableResolver ChainWrapper
in Chapter 5 in the spec document. - An
implementation
that wraps the head of the legacy PropertyResolver chain, as per sectionPropertyResolver ChainWrapper
in Chapter 5 in the spec document. - Any
ELResolver
instances added by calls to
.Application.addELResolver(jakarta.el.ELResolver)
- The default implementation throws
UnsupportedOperationException
and is provided for the sole purpose of not breaking existing applications that extend
.Application
- Overrides:
getELResolver
in classApplication
-
getExpressionFactory
public jakarta.el.ExpressionFactory getExpressionFactory()
Description copied from class:Application
Return the
ExpressionFactory
instance for this application. This instance is used by the convenience methodApplication.evaluateExpressionGet(jakarta.faces.context.FacesContext, java.lang.String, java.lang.Class)
.An implementation is provided that throws
UnsupportedOperationException
so that users that decorate theApplication
continue to work.- Overrides:
getExpressionFactory
in classApplication
- Returns:
-
getMessageBundle
public String getMessageBundle()
Description copied from class:Application
Return the fully qualified class name of theResourceBundle
to be used for JavaServer Faces messages for this application. If not explicitly set,null
is returned.- Specified by:
getMessageBundle
in classApplication
-
getNavigationHandler
public NavigationHandler getNavigationHandler()
Description copied from class:Application
Return the
instance that will be passed the outcome returned by any invoked application action for this web application. If not explicitly set, a default implementation must be provided that performs the functions described in theNavigationHandler
class description.NavigationHandler
- Specified by:
getNavigationHandler
in classApplication
-
getProjectStage
public ProjectStage getProjectStage()
Description copied from class:Application
Return the project stage for the currently running application instance. The default value is
ProjectStage.Production
The implementation of this method must perform the following algorithm or an equivalent with the same end result to determine the value to return.
- If the value has already been determined by a previous call to this method, simply return that value.
- Look for a
JNDI
environment entry under the key given by the value of
(return type of java.lang.String). If found, continue with the algorithm below, otherwise, look for an entry in theProjectStage.PROJECT_STAGE_JNDI_NAME
initParamMap
of theExternalContext
from the currentFacesContext
with the keyProjectStage.PROJECT_STAGE_PARAM_NAME
- If a value is found found, see if an enum constant can be obtained by calling
ProjectStage.valueOf()
, passing the value from theinitParamMap
. If this succeeds without exception, save the value and return it. - If not found, or any of the previous attempts to discover the enum constant value have failed, log a
descriptive error message, assign the value as
ProjectStage.Production
and return it.
- Overrides:
getProjectStage
in classApplication
-
getResourceBundle
public ResourceBundle getResourceBundle(FacesContext ctx, String name)
Description copied from class:Application
Find a
ResourceBundle
as defined in the application configuration resources under the specified name. If aResourceBundle
was defined for the name, return an instance that uses the locale of the current
.UIViewRoot
The default implementation throws
UnsupportedOperationException
and is provided for the sole purpose of not breaking existing applications that extend this class.- Overrides:
getResourceBundle
in classApplication
- Returns:
ResourceBundle
for the current UIViewRoot, otherwise null
-
getResourceHandler
public ResourceHandler getResourceHandler()
Description copied from class:Application
Return the singleton, stateless, thread-safe
for this application. The Faces implementation must support the following techniques for declaring an alternate implementation ofResourceHandler
ResourceHandler
.- The
ResourceHandler
implementation is declared in the application configuration resources by giving the fully qualified class name as the value of the<resource-handler>
element within theapplication
element. - RELEASE_PENDING(edburns) It can also be declared via an annotation as specified in [287-ConfigAnnotations].
In all of the above cases, the runtime must employ the decorator pattern as for every other pluggable artifact in Faces.
- Overrides:
getResourceHandler
in classApplication
- The
-
getStateManager
public StateManager getStateManager()
Description copied from class:Application
Return theStateManager
instance that will be utilized during the Restore View and Render Response phases of the request processing lifecycle. If not explicitly set, a default implementation must be provided that performs the functions described in theStateManager
description in the JavaServer Faces Specification.- Specified by:
getStateManager
in classApplication
-
getSupportedLocales
public Iterator<Locale> getSupportedLocales()
Description copied from class:Application
Return anIterator
over the supportedLocales
for this appication.- Specified by:
getSupportedLocales
in classApplication
-
getValidatorIds
public Iterator<String> getValidatorIds()
Description copied from class:Application
Return anIterator
over the set of currently registered validator ids for thisApplication
.- Specified by:
getValidatorIds
in classApplication
-
getViewHandler
public ViewHandler getViewHandler()
Description copied from class:Application
Set the
instance that will be utilized during theViewHandler
Restore View and Render Response
phases of the request processing lifecycle.- Specified by:
getViewHandler
in classApplication
- Returns:
-
getWrapped
public Application getWrapped()
Description copied from interface:FacesWrapper
A class that implements this interface uses this method to return an instance of the class being wrapped.- Specified by:
getWrapped
in interfaceFacesWrapper<Application>
- Returns:
- the instance of the class being wrapped
-
publishEvent
public void publishEvent(FacesContext facesContext, Class<? extends SystemEvent> systemEventClass, Class<?> sourceBaseType, Object source)
- Overrides:
publishEvent
in classApplication
-
publishEvent
public void publishEvent(FacesContext facesContext, Class<? extends SystemEvent> systemEventClass, Object source)
Description copied from class:Application
If there are one or more listeners for events of the type represented by
systemEventClass
, call those listeners,passing source as thesource
of the event. The implementation should be as fast as possible in determining whether or not a listener for the givensystemEventClass
andsource
has been installed, and should return immediately once such a determination has been made. The implementation ofpublishEvent
must honor the requirements stated inApplication.subscribeToEvent(java.lang.Class, java.lang.Class, jakarta.faces.event.SystemEventListener)
The default implementation must implement an algorithm semantically equivalent to the following to locate listener instances and to invoke them.
- If the
source
argument implements
, callSystemEventListenerHolder
on it, passing theSystemEventListenerHolder.getListenersForEventClass(java.lang.Class)
systemEventClass
argument. If the list is not empty, perform algorithmtraverseListenerList
on the list. - If any
Application
level listeners have been installed by previous calls to
, perform algorithmApplication.subscribeToEvent(java.lang.Class, java.lang.Class, SystemEventListener)
traverseListenerList
on the list. - If any
Application
level listeners have been installed by previous calls to
, perform algorithmApplication.subscribeToEvent(java.lang.Class, SystemEventListener)
traverseListenerList
on the list.
If the act of invoking the
processListener
method causes an
to be thrown, processing of the listeners must be aborted.AbortProcessingException
Algorithm
traverseListenerList
: For each listener in the list,- Call
, passing theSystemEventListener.isListenerForSource(java.lang.Object)
source
argument. If this returnsfalse
, take no action on the listener. - Otherwise, if the event to be passed to the listener instances has not yet been constructed, construct the
event, passing
source
as the argument to the one-argument constructor that takes anObject
. This same event instance must be passed to all listener instances. - Call
, passing the listener instance as the argument. If this returnsSystemEvent.isAppropriateListener(jakarta.faces.event.FacesListener)
false
, take no action on the listener. - Call
, passing the listener instance.SystemEvent.processListener(jakarta.faces.event.FacesListener)
- Overrides:
publishEvent
in classApplication
systemEventClass
- - The Class of event that is being published. Must be non-null.source
- - Thesource
for the event of type systemEventClass. Must be non-null
, and must implement
.SystemEventListenerHolder
- If the
-
removeELContextListener
public void removeELContextListener(jakarta.el.ELContextListener listener)
Description copied from class:Application
Remove the argument
listener
from the list ofELContextListeners
. Iflistener
is null, no exception is thrown and no action is performed. Iflistener
is not in the list, no exception is thrown and no action is performed.An implementation is provided that throws
UnsupportedOperationException
so that users that decorate theApplication
continue to work.- Overrides:
removeELContextListener
in classApplication
-
setActionListener
public void setActionListener(ActionListener listener)
Description copied from class:Application
Set the default
to be registered for allActionListener
components.ActionSource
- Specified by:
setActionListener
in classApplication
- Parameters:
listener
- - The new defaultActionListener
-
setDefaultLocale
public void setDefaultLocale(Locale locale)
Description copied from class:Application
Set the defaultLocale
for this application.- Specified by:
setDefaultLocale
in classApplication
- Parameters:
locale
- - The new defaultLocale
-
setDefaultRenderKitId
public void setDefaultRenderKitId(String renderKitId)
Description copied from class:Application
Return therenderKitId
to be used for rendering this application. If not explicitly set,null
is returned.- Specified by:
setDefaultRenderKitId
in classApplication
-
setMessageBundle
public void setMessageBundle(String bundle)
Description copied from class:Application
Set the fully qualified class name of theResourceBundle
to be used for JavaServer Faces messages for this application. See the JavaDocs for thejava.util.ResourceBundle
class for more information about the syntax for resource bundle names.- Specified by:
setMessageBundle
in classApplication
- Parameters:
bundle
- - Base name of the resource bundle to be used
-
setNavigationHandler
public void setNavigationHandler(NavigationHandler handler)
Description copied from class:Application
Set theNavigationHandler
instance that will be passed the outcome returned by any invoked application action for this web application.- Specified by:
setNavigationHandler
in classApplication
- Parameters:
handler
- - The new NavigationHandler instance
-
setResourceHandler
public void setResourceHandler(ResourceHandler resourceHandler)
- Overrides:
setResourceHandler
in classApplication
-
setStateManager
public void setStateManager(StateManager manager)
Description copied from class:Application
Set theStateManager
instance that will be utilized during theRestore View and Render Response
phases of the request processing lifecycle.- Specified by:
setStateManager
in classApplication
- Parameters:
manager
- The newStateManager
instance
-
setSupportedLocales
public void setSupportedLocales(Collection<Locale> locales)
Description copied from class:Application
Set theLocale
instances representing the supportedLocales
for this application.- Specified by:
setSupportedLocales
in classApplication
- Parameters:
locales
- The set of supportedLocales
for this application
-
setViewHandler
public void setViewHandler(ViewHandler handler)
Description copied from class:Application
Set theViewHandler
instance that will be utilized during theRestore View and Render Response
phases of the request processing lifecycle.- Specified by:
setViewHandler
in classApplication
- Parameters:
handler
- - The newViewHandler
instance
-
subscribeToEvent
public void subscribeToEvent(Class<? extends SystemEvent> systemEventClass, Class<?> sourceClass, SystemEventListener listener)
- Overrides:
subscribeToEvent
in classApplication
-
subscribeToEvent
public void subscribeToEvent(Class<? extends SystemEvent> systemEventClass, SystemEventListener listener)
- Overrides:
subscribeToEvent
in classApplication
-
unsubscribeFromEvent
public void unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass, Class<?> sourceClass, SystemEventListener listener)
- Overrides:
unsubscribeFromEvent
in classApplication
-
unsubscribeFromEvent
public void unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass, SystemEventListener listener)
- Overrides:
unsubscribeFromEvent
in classApplication
-
setFlowHandler
public void setFlowHandler(FlowHandler flowHandler)
- Overrides:
setFlowHandler
in classApplication
-
getFlowHandler
public FlowHandler getFlowHandler()
- Overrides:
getFlowHandler
in classApplication
- Returns:
-
setSearchExpressionHandler
public void setSearchExpressionHandler(SearchExpressionHandler searchExpressionHandler)
- Overrides:
setSearchExpressionHandler
in classApplication
-
getSearchExpressionHandler
public SearchExpressionHandler getSearchExpressionHandler()
- Overrides:
getSearchExpressionHandler
in classApplication
- Returns:
-
getSearchKeywordResolver
public SearchKeywordResolver getSearchKeywordResolver()
- Overrides:
getSearchKeywordResolver
in classApplication
-
addSearchKeywordResolver
public void addSearchKeywordResolver(SearchKeywordResolver resolver)
- Overrides:
addSearchKeywordResolver
in classApplication
-
-