- 
Nested Class Summary
- 
Field SummaryFields inherited from class jakarta.faces.context.FlashNULL_VALUE
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidclear()booleancontainsKey(Object key) booleancontainsValue(Object value) voidCalled after the execution of every lifecycle phase, this method allows implementations to take the necessary actions to provide the Flash scope contract as it applies to the request procesing lifecycle.voidCalled before the execution of every lifecycle phase, this method allows implementations to take the necessary actions to provide the Flash scope contract as it applies to the request procesing lifecycle.entrySet()booleanisEmpty()booleanReturn the value of this JavaBeans property for the flash for this session.booleanReturn the value of this property for the flash for this session.voidCauses a value stored with a previous call toFlash.putNow(java.lang.String, java.lang.Object), its Jakarta Expression Language equivalent, or to the requestMap, to be promoted to the flash so that is available on the next traversal through the lifecycle on this session.keySet()voidvoidPuts a value in the flash so that it can be accessed on this traversal of the lifecycle, rather than on the next traversal.voidsetKeepMessages(boolean newValue) Setter forkeepMessagesJavaBeans property.voidsetRedirect(boolean newValue) Setting this property totrueindicates that the next request on this session will be a redirect.intsize()values()Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Mapcompute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
- 
Constructor Details- 
NoOpFlashpublic NoOpFlash()
 
- 
- 
Method Details- 
doPostPhaseActionsDescription copied from class:FlashCalled after the execution of every lifecycle phase, this method allows implementations to take the necessary actions to provide the Flash scope contract as it applies to the request procesing lifecycle. - Specified by:
- doPostPhaseActionsin class- Flash
- Parameters:
- ctx- the- FacesContextfor this request.
 
- 
doPrePhaseActionsDescription copied from class:FlashCalled before the execution of every lifecycle phase, this method allows implementations to take the necessary actions to provide the Flash scope contract as it applies to the request procesing lifecycle. - Specified by:
- doPrePhaseActionsin class- Flash
- Parameters:
- ctx- the- FacesContextfor this request.
 
- 
isKeepMessagespublic boolean isKeepMessages()Description copied from class:FlashReturn the value of this JavaBeans property for the flash for this session. This value determines whether or not any FacesMessageinstances queued in the currentFacesContextmust be preserved so they are accessible on the next traversal of the lifecycle on this session, regardless of the request being a redirect after post, or a normal postback.Mapaccesses for the special key “keepMessages” must return the value of this JavaBeans property.Jakarta Expression Language Usage Example First page <html xmlns="http://www.w3.org/1999/xhtml" xmlns:c="jakarta.tags.core"> <!-- extra code removed --> <c:set target="#{flash}" property="keepMessages" value="true" />Next page <html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="jakarta.faces.html"> <!-- extra code removed --> <h:messages /> Any messages present on the first page must be displayed on this page.- Specified by:
- isKeepMessagesin class- Flash
- Returns:
- the boolean flag whether keeping messages or not.
 
- 
isRedirectpublic boolean isRedirect()Description copied from class:FlashReturn the value of this property for the flash for this session. This must be falseunless:- 
 Flash.setRedirect(boolean)was called for the current lifecycle traversal withtrueas the argument.
- 
 The current lifecycle traversal for this session is in the “execute” phase and the previous traversal had Flash.setRedirect(boolean)called withtrueas the argument.
 - Specified by:
- isRedirectin class- Flash
- Returns:
- the value of this property for the flash for this session.
 
- 
 
- 
keepDescription copied from class:FlashCauses a value stored with a previous call to Flash.putNow(java.lang.String, java.lang.Object), its Jakarta Expression Language equivalent, or to the requestMap, to be promoted to the flash so that is available on the next traversal through the lifecycle on this session.- Specified by:
- keepin class- Flash
- Parameters:
- key- if argument- keyis the name of an entry previously stored to the flash on this traversal through the lifecycle via a call to- Flash.putNow(java.lang.String, java.lang.Object), or to a set to the EL expression- #{flash.now.<key>}, or to the request- Map, to be promoted to the flash as if a call to- put()or a set to the expression- #{flash.<key>}was being called.
 
- 
putNowDescription copied from class:FlashPuts a value in the flash so that it can be accessed on this traversal of the lifecycle, rather than on the next traversal. This is simply an alias for putting a value in the request map. Jakarta Expression Language Usage Example <html xmlns="http://www.w3.org/1999/xhtml" xmlns:c="jakarta.tags.core"> <!-- extra code removed --> <c:set target="#{flash.now}" property="bar" value="barValue" /> <p>Value of \#{flash.now.bar}, should be barValue.</p> <h:outputText value="#{flash.now.bar}" />
- 
setKeepMessagespublic void setKeepMessages(boolean newValue) Description copied from class:FlashSetter for keepMessagesJavaBeans property. SeeFlash.isKeepMessages().- Specified by:
- setKeepMessagesin class- Flash
- Parameters:
- newValue- the new value for this property on this session.
 
- 
setRedirectpublic void setRedirect(boolean newValue) Description copied from class:FlashSetting this property to trueindicates that the next request on this session will be a redirect. Recall that on a redirect, the server sends a special response to the client instructing it to issue a new request to a specific URI. The implementation must insure that reading the value of this property on that request will returntrue.Jakarta Expression Language Usage Example <html xmlns="http://www.w3.org/1999/xhtml" xmlns:c="jakarta.tags.core"> <!-- extra code removed --> <c:set target="#{flash}" property="redirect" value="true" />- Specified by:
- setRedirectin class- Flash
- Parameters:
- newValue- the new value for this property on this session.
 
- 
clearpublic void clear()
- 
containsKey
- 
containsValue
- 
entrySet
- 
get
- 
isEmptypublic boolean isEmpty()
- 
keySet
- 
put
- 
putAll
- 
remove
- 
sizepublic int size()
- 
values
 
-