Interface PartialStateHolder

All Superinterfaces:
StateHolder
All Known Implementing Classes:
AjaxBehavior, BeanValidator, BehaviorBase, ClientBehaviorBase, DateTimeConverter, DoubleRangeValidator, EnumConverter, HtmlBody, HtmlColumn, HtmlCommandButton, HtmlCommandLink, HtmlCommandScript, HtmlDataTable, HtmlDoctype, HtmlForm, HtmlGraphicImage, HtmlHead, HtmlInputFile, HtmlInputHidden, HtmlInputSecret, HtmlInputText, HtmlInputTextarea, HtmlMessage, HtmlMessages, HtmlOutcomeTargetButton, HtmlOutcomeTargetLink, HtmlOutputFormat, HtmlOutputLabel, HtmlOutputLink, HtmlOutputText, HtmlPanelGrid, HtmlPanelGroup, HtmlSelectBooleanCheckbox, HtmlSelectManyCheckbox, HtmlSelectManyListbox, HtmlSelectManyMenu, HtmlSelectOneListbox, HtmlSelectOneMenu, HtmlSelectOneRadio, LengthValidator, LongRangeValidator, NumberConverter, RegexValidator, UIColumn, UICommand, UIComponent, UIComponentBase, UIData, UIForm, UIGraphic, UIImportConstants, UIInput, UIMessage, UIMessages, UINamingContainer, UIOutcomeTarget, UIOutput, UIPanel, UIParameter, UISelectBoolean, UISelectItem, UISelectItemGroup, UISelectItemGroups, UISelectItems, UISelectMany, UISelectOne, UIViewAction, UIViewParameter, UIViewRoot, UIWebsocket

public interface PartialStateHolder extends StateHolder

Components that want to leverage the partial state saving feature must implement this interface instead of implementing StateHolder, from which this interface inherits.

Since:
2.0
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Reset the PartialStateHolder to a non-delta tracking state.
    boolean
    Return true if delta state changes are being tracked, otherwise false
    void
    The runtime must ensure that the markInitialState() method is called on each instance of this interface in the view at the appropriate time to indicate the component is in its initial state.

    Methods inherited from interface StateHolder

    isTransient, restoreState, saveState, setTransient
    Modifier and Type
    Method
    Description
    boolean
    If true, the Object implementing this interface must not participate in state saving or restoring.
    void
    restoreState(FacesContext context, Object state)
    Perform any processing required to restore the state from the entries in the state Object.
    Gets the state of the instance as a Serializable Object.
    void
    setTransient(boolean newTransientValue)
    Denotes whether or not the Object implementing this interface must or must not participate in state saving or restoring.
  • Method Details

    • markInitialState

      void markInitialState()

      The runtime must ensure that the markInitialState() method is called on each instance of this interface in the view at the appropriate time to indicate the component is in its initial state. The implementor of the interface must ensure that initialStateMarked() returns true from the time markInitialState() is called until clearInitialState() is called, after which time initialStateMarked() must return false. Also, during the time that the instance returns true from initialStateMarked(), the implementation must return only the state that has changed in its implementation of StateHolder.saveState(FacesContext).

      Since:
      2.0
    • initialStateMarked

      boolean initialStateMarked()

      Return true if delta state changes are being tracked, otherwise false

      Returns:
      true if the initial state is marked, false otherwise.
      Since:
      2.0
    • clearInitialState

      void clearInitialState()

      Reset the PartialStateHolder to a non-delta tracking state.

      Since:
      2.0