Class FlashWrapper
- java.lang.Object
-
- javax.faces.context.Flash
-
- javax.faces.context.FlashWrapper
-
- All Implemented Interfaces:
java.util.Map<java.lang.String,java.lang.Object>,FacesWrapper<Flash>
public abstract class FlashWrapper extends Flash implements FacesWrapper<Flash>
Provides a simple implementation of
Flashthat can be subclassed by developers wishing to provide specialized behavior to an existingFlashinstance. The default implementation of all methods is to call through to the wrappedFlash.Usage: extend this class and override
getWrapped()to return the instance we are wrapping.- Since:
- 2.2
-
-
Field Summary
-
Fields inherited from class javax.faces.context.Flash
NULL_VALUE
-
-
Constructor Summary
Constructors Constructor Description FlashWrapper()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidclear()The default behavior of this method is to callMap.clear()on the wrappedFlashobject.booleancontainsKey(java.lang.Object key)The default behavior of this method is to callMap.containsKey(Object)on the wrappedFlashobject.booleancontainsValue(java.lang.Object value)The default behavior of this method is to callMap.containsValue(Object)on the wrappedFlashobject.voiddoPostPhaseActions(FacesContext ctx)The default behavior of this method is to callFlash.doPostPhaseActions(FacesContext)on the wrappedFlashobject.voiddoPrePhaseActions(FacesContext ctx)The default behavior of this method is to callFlash.doPrePhaseActions(FacesContext)on the wrappedFlashobject.java.util.Set<java.util.Map.Entry<java.lang.String,java.lang.Object>>entrySet()The default behavior of this method is to callMap.entrySet()on the wrappedFlashobject.java.lang.Objectget(java.lang.Object key)The default behavior of this method is to callMap.get(Object)on the wrappedFlashobject.abstract FlashgetWrapped()A class that implements this interface uses this method to return an instance of the class being wrapped.booleanisEmpty()The default behavior of this method is to callMap.isEmpty()on the wrappedFlashobject.booleanisKeepMessages()The default behavior of this method is to callFlash.isKeepMessages()on the wrappedFlashobject.booleanisRedirect()The default behavior of this method is to callFlash.isRedirect()on the wrappedFlashobject.voidkeep(java.lang.String key)The default behavior of this method is to callFlash.keep(String)on the wrappedFlashobject.java.util.Set<java.lang.String>keySet()The default behavior of this method is to callMap.keySet()on the wrappedFlashobject.java.lang.Objectput(java.lang.String key, java.lang.Object value)The default behavior of this method is to callMap.put(K, V)on the wrappedFlashobject.voidputAll(java.util.Map<? extends java.lang.String,? extends java.lang.Object> m)The default behavior of this method is to callMap.putAll(Map)on the wrappedFlashobject.voidputNow(java.lang.String key, java.lang.Object value)The default behavior of this method is to callFlash.putNow(String, Object)on the wrappedFlashobject.java.lang.Objectremove(java.lang.Object key)The default behavior of this method is to callMap.remove(Object)on the wrappedFlashobject.voidsetKeepMessages(boolean newValue)The default behavior of this method is to callFlash.setKeepMessages(boolean)on the wrappedFlashobject.voidsetRedirect(boolean newValue)The default behavior of this method is to callFlash.setRedirect(boolean)on the wrappedFlashobject.intsize()The default behavior of this method is to callMap.size()on the wrappedFlashobject.java.util.Collection<java.lang.Object>values()The default behavior of this method is to callMap.values()on the wrappedFlashobject.
-
-
-
Method Detail
-
getWrapped
public abstract Flash getWrapped()
Description copied from interface:FacesWrapperA class that implements this interface uses this method to return an instance of the class being wrapped.
- Specified by:
getWrappedin interfaceFacesWrapper<Flash>
-
doPostPhaseActions
public void doPostPhaseActions(FacesContext ctx)
The default behavior of this method is to call
Flash.doPostPhaseActions(FacesContext)on the wrappedFlashobject.- Specified by:
doPostPhaseActionsin classFlash- Parameters:
ctx- theFacesContextfor this request.- Since:
- 2.2
-
doPrePhaseActions
public void doPrePhaseActions(FacesContext ctx)
The default behavior of this method is to call
Flash.doPrePhaseActions(FacesContext)on the wrappedFlashobject.- Specified by:
doPrePhaseActionsin classFlash- Parameters:
ctx- theFacesContextfor this request.- Since:
- 2.2
-
isKeepMessages
public boolean isKeepMessages()
The default behavior of this method is to call
Flash.isKeepMessages()on the wrappedFlashobject.- Specified by:
isKeepMessagesin classFlash- Since:
- 2.2
-
isRedirect
public boolean isRedirect()
The default behavior of this method is to call
Flash.isRedirect()on the wrappedFlashobject.- Specified by:
isRedirectin classFlash- Since:
- 2.2
-
keep
public void keep(java.lang.String key)
The default behavior of this method is to call
Flash.keep(String)on the wrappedFlashobject.- Specified by:
keepin classFlash- Parameters:
key- if argumentkeyis the name of an entry previously stored to the flash on this traversal through the lifecycle via a call toFlash.putNow(java.lang.String, java.lang.Object), or to a set to the EL expression#{flash.now.<key>}, or to the requestMap, to be promoted to the flash as if a call toput()or a set to the expression#{flash.<key>}was being called.- Since:
- 2.2
-
putNow
public void putNow(java.lang.String key, java.lang.Object value)The default behavior of this method is to call
Flash.putNow(String, Object)on the wrappedFlashobject.
-
setKeepMessages
public void setKeepMessages(boolean newValue)
The default behavior of this method is to call
Flash.setKeepMessages(boolean)on the wrappedFlashobject.- Specified by:
setKeepMessagesin classFlash- Parameters:
newValue- the new value for this property on this session.- Since:
- 2.2
-
setRedirect
public void setRedirect(boolean newValue)
The default behavior of this method is to call
Flash.setRedirect(boolean)on the wrappedFlashobject.- Specified by:
setRedirectin classFlash- Parameters:
newValue- the new value for this property on this session.- Since:
- 2.2
-
clear
public void clear()
The default behavior of this method is to call
Map.clear()on the wrappedFlashobject.- Specified by:
clearin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
containsKey
public boolean containsKey(java.lang.Object key)
The default behavior of this method is to call
Map.containsKey(Object)on the wrappedFlashobject.- Specified by:
containsKeyin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
containsValue
public boolean containsValue(java.lang.Object value)
The default behavior of this method is to call
Map.containsValue(Object)on the wrappedFlashobject.- Specified by:
containsValuein interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
entrySet
public java.util.Set<java.util.Map.Entry<java.lang.String,java.lang.Object>> entrySet()
The default behavior of this method is to call
Map.entrySet()on the wrappedFlashobject.- Specified by:
entrySetin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
get
public java.lang.Object get(java.lang.Object key)
The default behavior of this method is to call
Map.get(Object)on the wrappedFlashobject.- Specified by:
getin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
isEmpty
public boolean isEmpty()
The default behavior of this method is to call
Map.isEmpty()on the wrappedFlashobject.- Specified by:
isEmptyin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
keySet
public java.util.Set<java.lang.String> keySet()
The default behavior of this method is to call
Map.keySet()on the wrappedFlashobject.- Specified by:
keySetin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
put
public java.lang.Object put(java.lang.String key, java.lang.Object value)The default behavior of this method is to call
Map.put(K, V)on the wrappedFlashobject.- Specified by:
putin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
putAll
public void putAll(java.util.Map<? extends java.lang.String,? extends java.lang.Object> m)
The default behavior of this method is to call
Map.putAll(Map)on the wrappedFlashobject.- Specified by:
putAllin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
remove
public java.lang.Object remove(java.lang.Object key)
The default behavior of this method is to call
Map.remove(Object)on the wrappedFlashobject.- Specified by:
removein interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
size
public int size()
The default behavior of this method is to call
Map.size()on the wrappedFlashobject.- Specified by:
sizein interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
values
public java.util.Collection<java.lang.Object> values()
The default behavior of this method is to call
Map.values()on the wrappedFlashobject.- Specified by:
valuesin interfacejava.util.Map<java.lang.String,java.lang.Object>- Since:
- 2.2
-
-