public abstract class ApplicationWrapper extends Application implements FacesWrapper<Application>
Provides a simple implementation of
Application
that can be subclassed by developers wishing
to provide specialized behavior to an existing Application
instance. The default implementation of all methods
is to call through to the wrapped Application
.
Usage: extend this class and override getWrapped()
to
return the instance we are wrapping.
Constructor and Description |
---|
ApplicationWrapper() |
Modifier and Type | Method and Description |
---|---|
void |
addBehavior(String behaviorId,
String behaviorClass)
The default behavior of this method
is to call |
void |
addComponent(String componentType,
String componentClass)
The default behavior of this method
is to call |
void |
addConverter(Class<?> targetClass,
String converterClass)
The default behavior of this method
is to call |
void |
addConverter(String converterId,
String converterClass)
The default behavior of this method
is to call |
void |
addDefaultValidatorId(String validatorId)
The default behavior of this method
is to call |
void |
addELContextListener(ELContextListener listener)
The default behavior of this method
is to call |
void |
addELResolver(ELResolver resolver)
The default behavior of this method
is to call |
void |
addValidator(String validatorId,
String validatorClass)
The default behavior of this method
is to call |
Behavior |
createBehavior(String behaviorId)
The default behavior of this method
is to call |
UIComponent |
createComponent(FacesContext context,
Resource componentResource)
The default behavior of this method
is to call |
UIComponent |
createComponent(FacesContext context,
String componentType,
String rendererType)
The default behavior of this method
is to call |
UIComponent |
createComponent(String componentType)
The default behavior of this method
is to call |
UIComponent |
createComponent(ValueBinding componentBinding,
FacesContext context,
String componentType)
The default behavior of this method
is to call |
UIComponent |
createComponent(ValueExpression componentExpression,
FacesContext context,
String componentType)
The default behavior of this method
is to call |
UIComponent |
createComponent(ValueExpression componentExpression,
FacesContext context,
String componentType,
String rendererType)
The default behavior of this method
is to call |
Converter |
createConverter(Class<?> targetClass)
The default behavior of this method
is to call |
Converter |
createConverter(String converterId)
The default behavior of this method
is to call |
MethodBinding |
createMethodBinding(String ref,
Class<?>[] params)
The default behavior of this method
is to call |
Validator |
createValidator(String validatorId)
The default behavior of this method
is to call |
ValueBinding |
createValueBinding(String ref)
The default behavior of this method
is to call |
<T> T |
evaluateExpressionGet(FacesContext context,
String expression,
Class<? extends T> expectedType)
The default behavior of this method
is to call |
ActionListener |
getActionListener()
The default behavior of this method
is to call |
Iterator<String> |
getBehaviorIds()
The default behavior of this method
is to call |
Iterator<String> |
getComponentTypes()
The default behavior of this method
is to call |
Iterator<String> |
getConverterIds()
The default behavior of this method
is to call |
Iterator<Class<?>> |
getConverterTypes()
The default behavior of this method
is to call |
Locale |
getDefaultLocale()
The default behavior of this method
is to call |
String |
getDefaultRenderKitId()
The default behavior of this method
is to call |
Map<String,String> |
getDefaultValidatorInfo()
The default behavior of this method
is to call |
ELContextListener[] |
getELContextListeners()
The default behavior of this method
is to call |
ELResolver |
getELResolver()
The default behavior of this method
is to call |
ExpressionFactory |
getExpressionFactory()
The default behavior of this method
is to call |
String |
getMessageBundle()
The default behavior of this method
is to call |
NavigationHandler |
getNavigationHandler()
The default behavior of this method
is to call |
ProjectStage |
getProjectStage()
The default behavior of this method
is to call |
PropertyResolver |
getPropertyResolver()
The default behavior of this method
is to call |
ResourceBundle |
getResourceBundle(FacesContext ctx,
String name)
The default behavior of this method
is to call |
ResourceHandler |
getResourceHandler()
The default behavior of this method
is to call |
StateManager |
getStateManager()
The default behavior of this method
is to call |
Iterator<Locale> |
getSupportedLocales()
The default behavior of this method
is to call |
Iterator<String> |
getValidatorIds()
The default behavior of this method
is to call |
VariableResolver |
getVariableResolver()
The default behavior of this method
is to call |
ViewHandler |
getViewHandler()
The default behavior of this method
is to call |
abstract Application |
getWrapped()
A class that implements this interface uses this method to return an instance of the class being wrapped. |
void |
publishEvent(FacesContext context,
Class<? extends SystemEvent> systemEventClass,
Class<?> sourceBaseType,
Object source)
The default behavior of this method
is to call |
void |
publishEvent(FacesContext context,
Class<? extends SystemEvent> systemEventClass,
Object source)
The default behavior of this method
is to call |
void |
removeELContextListener(ELContextListener listener)
The default behavior of this method
is to call |
void |
setActionListener(ActionListener listener)
The default behavior of this method
is to call |
void |
setDefaultLocale(Locale locale)
The default behavior of this method
is to call |
void |
setDefaultRenderKitId(String renderKitId)
The default behavior of this method
is to call |
void |
setMessageBundle(String bundle)
The default behavior of this method
is to call |
void |
setNavigationHandler(NavigationHandler handler)
The default behavior of this method
is to call |
void |
setPropertyResolver(PropertyResolver resolver)
The default behavior of this method
is to call |
void |
setResourceHandler(ResourceHandler resourceHandler)
The default behavior of this method
is to call |
void |
setStateManager(StateManager manager)
The default behavior of this method
is to call |
void |
setSupportedLocales(Collection<Locale> locales)
The default behavior of this method
is to call |
void |
setVariableResolver(VariableResolver resolver)
The default behavior of this method
is to call |
void |
setViewHandler(ViewHandler handler)
The default behavior of this method
is to call |
void |
subscribeToEvent(Class<? extends SystemEvent> systemEventClass,
Class<?> sourceClass,
SystemEventListener listener)
The default behavior of this method
is to call |
void |
subscribeToEvent(Class<? extends SystemEvent> systemEventClass,
SystemEventListener listener)
The default behavior of this method
is to call |
void |
unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass,
Class<?> sourceClass,
SystemEventListener listener)
The default behavior of this method
is to call |
void |
unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass,
SystemEventListener listener)
The default behavior of this method
is to call |
addConverter, createConverter, createMethodBinding, evaluateExpressionGet
public abstract Application getWrapped()
FacesWrapper
A class that implements this interface uses this method to return an instance of the class being wrapped.
getWrapped
in interface FacesWrapper<Application>
public ActionListener getActionListener()
The default behavior of this method
is to call Application.getActionListener()
on the
wrapped Application
object.
getActionListener
in class Application
public void setActionListener(ActionListener listener)
The default behavior of this method
is to call Application.setActionListener(javax.faces.event.ActionListener)
on the wrapped Application
object.
setActionListener
in class Application
listener
- The new default ActionListener
public Locale getDefaultLocale()
The default behavior of this method
is to call Application.getDefaultLocale()
on the
wrapped Application
object.
getDefaultLocale
in class Application
public void setDefaultLocale(Locale locale)
The default behavior of this method
is to call Application.setDefaultLocale(java.util.Locale)
on the
wrapped Application
object.
setDefaultLocale
in class Application
locale
- The new default Locale
public String getDefaultRenderKitId()
The default behavior of this method
is to call Application.getDefaultRenderKitId()
on the
wrapped Application
object.
getDefaultRenderKitId
in class Application
public void addDefaultValidatorId(String validatorId)
The default behavior of this method
is to call Application#addDefaultValidatorId(String)
on the
wrapped Application
object.
public Map<String,String> getDefaultValidatorInfo()
The default behavior of this method
is to call Application#getDefaultValidatorInfo
on the
wrapped Application
object.
public void setDefaultRenderKitId(String renderKitId)
The default behavior of this method
is to call Application.setDefaultRenderKitId(String)
on the
wrapped Application
object.
setDefaultRenderKitId
in class Application
public String getMessageBundle()
The default behavior of this method
is to call Application.getMessageBundle()
on the
wrapped Application
object.
getMessageBundle
in class Application
public void setMessageBundle(String bundle)
The default behavior of this method
is to call Application.setMessageBundle(String)
on the
wrapped Application
object.
setMessageBundle
in class Application
bundle
- Base name of the resource bundle to be usedpublic NavigationHandler getNavigationHandler()
The default behavior of this method
is to call Application.getNavigationHandler()
on the
wrapped Application
object.
getNavigationHandler
in class Application
public void setNavigationHandler(NavigationHandler handler)
The default behavior of this method
is to call Application.setNavigationHandler(NavigationHandler)
on the
wrapped Application
object.
setNavigationHandler
in class Application
handler
- The new NavigationHandler
instancepublic PropertyResolver getPropertyResolver()
The default behavior of this method
is to call Application.getPropertyResolver()
on the
wrapped Application
object.
getPropertyResolver
in class Application
public void setPropertyResolver(PropertyResolver resolver)
The default behavior of this method
is to call Application.setPropertyResolver(javax.faces.el.PropertyResolver)
on the
wrapped Application
object.
setPropertyResolver
in class Application
resolver
- The new PropertyResolver
instancepublic VariableResolver getVariableResolver()
The default behavior of this method
is to call Application.getVariableResolver()
on the
wrapped Application
object.
getVariableResolver
in class Application
public void setVariableResolver(VariableResolver resolver)
The default behavior of this method
is to call Application.setVariableResolver(javax.faces.el.VariableResolver)
on the
wrapped Application
object.
setVariableResolver
in class Application
resolver
- The new VariableResolver
instancepublic ViewHandler getViewHandler()
The default behavior of this method
is to call Application.getViewHandler()
on the
wrapped Application
object.
getViewHandler
in class Application
public void setViewHandler(ViewHandler handler)
The default behavior of this method
is to call Application.setViewHandler(ViewHandler)
on the
wrapped Application
object.
setViewHandler
in class Application
handler
- The new ViewHandler
instancepublic StateManager getStateManager()
The default behavior of this method
is to call Application.getStateManager()
on the
wrapped Application
object.
getStateManager
in class Application
public void setStateManager(StateManager manager)
The default behavior of this method
is to call Application.setStateManager(StateManager)
on the
wrapped Application
object.
setStateManager
in class Application
manager
- The new StateManager
instancepublic void addComponent(String componentType, String componentClass)
The default behavior of this method
is to call Application.addComponent(String, String)
on the
wrapped Application
object.
addComponent
in class Application
componentType
- The component type to be registeredcomponentClass
- The fully qualified class name of the
corresponding UIComponent
implementationpublic UIComponent createComponent(String componentType) throws FacesException
The default behavior of this method
is to call Application.createComponent(String)
on the
wrapped Application
object.
createComponent
in class Application
componentType
- The component type for which to create and
return a new UIComponent
instanceFacesException
- if a UIComponent
of the
specified type cannot be createdpublic UIComponent createComponent(ValueBinding componentBinding, FacesContext context, String componentType) throws FacesException
The default behavior of this method
is to call Application.createComponent(javax.faces.el.ValueBinding, javax.faces.context.FacesContext, String)
on the wrapped Application
object.
createComponent
in class Application
componentBinding
- ValueBinding
representing a
component value binding expression (typically specified by the
component
attribute of a custom tag)context
- FacesContext
for the current requestcomponentType
- Component type to create if the ValueBinding
does not return a component instanceFacesException
- if a UIComponent
cannot be createdpublic Iterator<String> getComponentTypes()
The default behavior of this method
is to call Application.getComponentTypes()
on the
wrapped Application
object.
getComponentTypes
in class Application
public void addConverter(String converterId, String converterClass)
The default behavior of this method
is to call Application.addConverter(String, String)
on the
wrapped Application
object.
addConverter
in class Application
converterId
- The converter id to be registeredconverterClass
- The fully qualified class name of the
corresponding Converter
implementationpublic void addConverter(Class<?> targetClass, String converterClass)
The default behavior of this method
is to call Application.addConverter(Class, String)
on the
wrapped Application
object.
public Converter createConverter(String converterId)
The default behavior of this method
is to call Application.createConverter(String)
on the
wrapped Application
object.
createConverter
in class Application
converterId
- The converter id for which to create and
return a new Converter
instancepublic Converter createConverter(Class<?> targetClass)
The default behavior of this method
is to call Application.createConverter(Class)
on the
wrapped Application
object.
public Iterator<String> getConverterIds()
The default behavior of this method
is to call Application.getConverterIds()
on the
wrapped Application
object.
getConverterIds
in class Application
public Iterator<Class<?>> getConverterTypes()
The default behavior of this method
is to call Application.getConverterTypes()
on the
wrapped Application
object.
public MethodBinding createMethodBinding(String ref, Class<?>[] params) throws ReferenceSyntaxException
The default behavior of this method
is to call Application.createMethodBinding(String, Class[])
on the
wrapped Application
object.
ReferenceSyntaxException
public Iterator<Locale> getSupportedLocales()
The default behavior of this method
is to call Application.getSupportedLocales()
on the
wrapped Application
object.
getSupportedLocales
in class Application
public void setSupportedLocales(Collection<Locale> locales)
The default behavior of this method
is to call Application.setSupportedLocales(java.util.Collection)
on the
wrapped Application
object.
setSupportedLocales
in class Application
locales
- The set of supported Locale
s
for this applicationpublic void addBehavior(String behaviorId, String behaviorClass)
The default behavior of this method
is to call Application#addBehavior(String, String)
on the
wrapped Application
object.
public Behavior createBehavior(String behaviorId) throws FacesException
The default behavior of this method
is to call Application#createBehavior(String)
on the
wrapped Application
object.
FacesException
public Iterator<String> getBehaviorIds()
The default behavior of this method
is to call Application#getBehaviorIds
on the
wrapped Application
object.
public void addValidator(String validatorId, String validatorClass)
The default behavior of this method
is to call Application.addValidator(String, String)
on the
wrapped Application
object.
addValidator
in class Application
validatorId
- The validator id to be registeredvalidatorClass
- The fully qualified class name of the
corresponding Validator
implementationpublic Validator createValidator(String validatorId) throws FacesException
The default behavior of this method
is to call Application.createValidator(String)
on the
wrapped Application
object.
createValidator
in class Application
validatorId
- The validator id for which to create and
return a new Validator
instanceFacesException
- if a Validator
of the
specified id cannot be createdpublic Iterator<String> getValidatorIds()
The default behavior of this method
is to call Application.getValidatorIds()
on the
wrapped Application
object.
getValidatorIds
in class Application
public ValueBinding createValueBinding(String ref) throws ReferenceSyntaxException
The default behavior of this method
is to call Application.createValueBinding(String)
on the
wrapped Application
object.
createValueBinding
in class Application
ref
- Value binding expression for which to return a
ValueBinding
instanceReferenceSyntaxException
- if the specified ref
has invalid syntaxpublic ResourceHandler getResourceHandler()
The default behavior of this method
is to call Application#getResourceHandler
on the
wrapped Application
object.
public void setResourceHandler(ResourceHandler resourceHandler)
The default behavior of this method
is to call Application#setResourceHandler(ResourceHandler)
on the
wrapped Application
object.
public ResourceBundle getResourceBundle(FacesContext ctx, String name)
The default behavior of this method
is to call Application.getResourceBundle(javax.faces.context.FacesContext, String)
on the
wrapped Application
object.
getResourceBundle
in class Application
ResourceBundle
for the current UIViewRoot,
otherwise nullpublic ProjectStage getProjectStage()
The default behavior of this method
is to call Application#getProjectStage
on the
wrapped Application
object.
public void addELResolver(ELResolver resolver)
The default behavior of this method
is to call Application.addELResolver(javax.el.ELResolver)
on the
wrapped Application
object.
addELResolver
in class Application
public ELResolver getELResolver()
The default behavior of this method
is to call Application.getELResolver()
on the
wrapped Application
object.
getELResolver
in class Application
public UIComponent createComponent(ValueExpression componentExpression, FacesContext context, String componentType) throws FacesException
The default behavior of this method
is to call Application.createComponent(javax.el.ValueExpression, javax.faces.context.FacesContext, String)
on the wrapped Application
object.
createComponent
in class Application
componentExpression
- ValueExpression
representing a
component value expression (typically specified by the
component
attribute of a custom tag)context
- FacesContext
for the current requestcomponentType
- Component type to create if the ValueExpression
does not return a component instanceFacesException
- if a UIComponent
cannot be createdpublic UIComponent createComponent(ValueExpression componentExpression, FacesContext context, String componentType, String rendererType)
The default behavior of this method
is to call Application#createComponent(javax.el.ValueExpression, javax.faces.context.FacesContext, String, String)
on the wrapped Application
object.
public UIComponent createComponent(FacesContext context, String componentType, String rendererType)
The default behavior of this method
is to call Application#createComponent(javax.faces.context.FacesContext, String, String)
on the wrapped Application
object.
public UIComponent createComponent(FacesContext context, Resource componentResource)
The default behavior of this method
is to call Application#createComponent(javax.faces.context.FacesContext, Resource)
on the wrapped Application
object.
public ExpressionFactory getExpressionFactory()
The default behavior of this method
is to call Application.getExpressionFactory()
on the
wrapped Application
object.
getExpressionFactory
in class Application
public <T> T evaluateExpressionGet(FacesContext context, String expression, Class<? extends T> expectedType) throws ELException
The default behavior of this method
is to call Application.evaluateExpressionGet(javax.faces.context.FacesContext, String, Class)
on the wrapped Application
object.
ELException
public void addELContextListener(ELContextListener listener)
The default behavior of this method
is to call Application.addELContextListener(javax.el.ELContextListener)
on the
wrapped Application
object.
addELContextListener
in class Application
public void removeELContextListener(ELContextListener listener)
The default behavior of this method
is to call Application.removeELContextListener(javax.el.ELContextListener)
on the
wrapped Application
object.
removeELContextListener
in class Application
public ELContextListener[] getELContextListeners()
The default behavior of this method
is to call Application.getELContextListeners()
on the
wrapped Application
object.
getELContextListeners
in class Application
public void publishEvent(FacesContext context, Class<? extends SystemEvent> systemEventClass, Object source)
The default behavior of this method
is to call Application#publishEvent(javax.faces.context.FacesContext, Class, Object)
on the wrapped Application
object.
public void publishEvent(FacesContext context, Class<? extends SystemEvent> systemEventClass, Class<?> sourceBaseType, Object source)
The default behavior of this method
is to call Application#publishEvent(javax.faces.context.FacesContext, Class, Class, Object)
on the wrapped Application
object.
public void subscribeToEvent(Class<? extends SystemEvent> systemEventClass, Class<?> sourceClass, SystemEventListener listener)
The default behavior of this method
is to call Application#subscribeToEvent(Class, Class, javax.faces.event.SystemEventListener)
on the
wrapped Application
object.
public void subscribeToEvent(Class<? extends SystemEvent> systemEventClass, SystemEventListener listener)
The default behavior of this method
is to call Application#subscribeToEvent(Class, javax.faces.event.SystemEventListener)
on the
wrapped Application
object.
public void unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass, Class<?> sourceClass, SystemEventListener listener)
The default behavior of this method
is to call Application#unsubscribeFromEvent(Class, Class, javax.faces.event.SystemEventListener)
on the
wrapped Application
object.
public void unsubscribeFromEvent(Class<? extends SystemEvent> systemEventClass, SystemEventListener listener)
The default behavior of this method
is to call Application#unsubscribeFromEvent(Class, javax.faces.event.SystemEventListener)
on the
wrapped Application
object.
Copyright © 2018 JBoss by Red Hat. All rights reserved.