- java.lang.Object
-
- org.omnifaces.component.EditableValueHolderStateHelper
-
public final class EditableValueHolderStateHelper extends Object
Helper class to save and restore state of anEditableValueHolder
.- Author:
- Bauke Scholtz.
-
-
Constructor Summary
Constructors Constructor Description EditableValueHolderStateHelper()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static EditableValueHolderStateHelper
get(StateHelper stateHelper, String clientId)
Returns the state helper of theEditableValueHolder
child associated with the given client ID.void
restore(EditableValueHolder holder)
Restore the state of the givenEditableValueHolder
.static void
restore(FacesContext context, StateHelper stateHelper, Iterator<UIComponent> children)
Restore state of anyEditableValueHolder
children.void
save(EditableValueHolder holder)
Save the state of the givenEditableValueHolder
.static void
save(FacesContext context, StateHelper stateHelper, Iterator<UIComponent> children)
Save state of anyEditableValueHolder
children.
-
-
-
Method Detail
-
save
public void save(EditableValueHolder holder)
Save the state of the givenEditableValueHolder
.- Parameters:
holder
- TheEditableValueHolder
to save the state for.
-
restore
public void restore(EditableValueHolder holder)
Restore the state of the givenEditableValueHolder
.- Parameters:
holder
- TheEditableValueHolder
to restore the state for.
-
save
public static void save(FacesContext context, StateHelper stateHelper, Iterator<UIComponent> children)
Save state of anyEditableValueHolder
children.- Parameters:
context
- The faces context to work with.stateHelper
- The state helper of the parent component.children
- An iterator with all child facets and components of the parent component as obtained byUIComponentBase.getFacetsAndChildren()
.
-
restore
public static void restore(FacesContext context, StateHelper stateHelper, Iterator<UIComponent> children)
Restore state of anyEditableValueHolder
children.- Parameters:
context
- The faces context to work with.stateHelper
- The state helper of the parent component.children
- An iterator with all child facets and components of the parent component as obtained byUIComponentBase.getFacetsAndChildren()
.
-
get
public static EditableValueHolderStateHelper get(StateHelper stateHelper, String clientId)
Returns the state helper of theEditableValueHolder
child associated with the given client ID.- Parameters:
stateHelper
- The state helper of the parent component.clientId
- The client ID of theEditableValueHolder
child to return the state helper for.- Returns:
- The state helper of the
EditableValueHolder
child associated with the given client ID.
-
-