Package org.apache.myfaces.view
Class ViewScopeProxyMap
- All Implemented Interfaces:
StateHolder,Serializable,Cloneable,Map<String,Object>
This wrapper has these objectives:
- Isolate the part that needs to be saved with the view (viewScopeId) from
the part that should remain into session (bean map). This class will be
serialized when UIViewRoot.saveState() is called.
- Decouple the way how the view scope map is stored. For example, in
CDI view scope a session scope bean is used, and in default view scope
the same session map is used but using a prefix.
- Author:
- Leonardo Uribe
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()booleancontainsKey(Object key) booleancontainsValue(Object value) entrySet()voidforceDelegateCreation(FacesContext facesContext) booleanisEmpty()booleankeySet()voidvoidrestoreState(FacesContext context, Object state) saveState(FacesContext context) voidsetTransient(boolean newTransientValue) intsize()values()Methods inherited from class java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAllMethods inherited from class java.util.AbstractMap
equals, hashCode, toString
-
Constructor Details
-
ViewScopeProxyMap
public ViewScopeProxyMap()
-
-
Method Details
-
getViewScopeId
-
forceDelegateCreation
-
getDelegate
-
size
public int size() -
isEmpty
public boolean isEmpty() -
containsKey
- Specified by:
containsKeyin interfaceMap<String,Object> - Overrides:
containsKeyin classHashMap<String,Object>
-
containsValue
- Specified by:
containsValuein interfaceMap<String,Object> - Overrides:
containsValuein classHashMap<String,Object>
-
get
-
put
-
remove
-
putAll
-
clear
public void clear() -
keySet
-
values
-
entrySet
-
restoreState
- Specified by:
restoreStatein interfaceStateHolder
-
saveState
- Specified by:
saveStatein interfaceStateHolder
-
isTransient
public boolean isTransient()- Specified by:
isTransientin interfaceStateHolder
-
setTransient
public void setTransient(boolean newTransientValue) - Specified by:
setTransientin interfaceStateHolder
-