Top Description Methods
javax.faces.component

public Interface TransientStateHolder

Known Direct Subinterfaces
javax.faces.component.TransientStateHelper
Known Direct Implementers
javax.faces.component.UIComponent

This interface is implemented by classes that need to save state that is expected to be available only within the scope of the current request.

An implementor must implement both saveTransientState and restoreTransientState methods in this class, since these two methods have a tightly coupled contract between themselves. In other words, if there is an inheritance hierarchy, it is not permissible to have the saveTransientState and restoreTransientState methods reside at different levels of the hierarchy.

An example of transient state is the "submitted" property on forms.

Since
2.1

Method Summary

Modifier and TypeMethod and Description
public void
restoreTransientState(FacesContext
the Faces context
context
,
Object
the object containing transient values
state
)

Restore the "transient state" using the object passed as state.

public Object

Returns:

object containing transient values
saveTransientState
(FacesContext
the Faces context.
context
)

Return the object containing related "transient states".

Method Detail

restoreTransientStateback to summary
public void restoreTransientState(FacesContext context, Object state)

Restore the "transient state" using the object passed as state.

If the state argument is null clear any previous transient state if any and return.

Parameters
context:FacesContext

the Faces context

state:Object

the object containing transient values

Since
2.1
saveTransientStateback to summary
public Object saveTransientState(FacesContext context)

Return the object containing related "transient states". that could be used later to restore the "transient state".

Parameters
context:FacesContext

the Faces context.

Returns:Object

object containing transient values

Since
2.1