Examples of processSaveState()


Examples of javax.faces.component.UIViewRoot.processSaveState()

        UIViewRoot viewRoot = facesContext.getViewRoot();
        if (viewRoot.isTransient()) {
            return null;
        }

        Object serializedComponentStates = viewRoot.processSaveState(facesContext);
        //Locale is a state attribute of UIViewRoot and need not be saved explicitly
        if (log.isTraceEnabled()) log.trace("Exiting getComponentStateToSave");
        return serializedComponentStates;
    }
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

            if (view.getAttributes().containsKey(COMPONENT_ADDED_AFTER_BUILD_VIEW))
            {
                ensureClearInitialState(view);
                states = new Object[]{
                            internalBuildTreeStructureToSave(view),
                            view.processSaveState(context)};
            }
            else
            {
                states = new HashMap<String, Object>();
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

    SerializedView serializedView = null;
    UIViewRoot viewRoot = context.getViewRoot();
    if (null != viewRoot && (!viewRoot.isTransient()) ) {
      TreeStrutureNode treeStructure = new TreeStrutureNode();
      treeStructure.apply(context, viewRoot, new HashSet());
      Object treeState = viewRoot.processSaveState(context);
      Object state[] = { treeState, getAdditionalState(context) };
      if (isSavingStateInClient(context)) {
        serializedView = new SerializedView(treeStructure, state);
      } else {
        serializedView = saveStateInSession(context, treeStructure,
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

        mockState.setCount(123);
        adaptor.encodeBegin(facesContext);

        UIViewRoot viewRoot = facesContext.getViewRoot();
        Object treeState = viewRoot.processSaveState(facesContext);
        UIViewRoot root = (UIViewRoot) viewRoot.getClass().newInstance();
        UIDataAdaptor restoredAdaptor = new MockDataAdaptor();

        root.getChildren().add(restoredAdaptor);
        root.processRestoreState(facesContext, treeState);
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

        mockState = (MockComponentState) adaptor.getComponentState();
        mockState.setCount(321);
        adaptor.encodeBegin(facesContext);

        UIViewRoot viewRoot = facesContext.getViewRoot();
        Object treeState = viewRoot.processSaveState(facesContext);
        UIViewRoot root = (UIViewRoot) viewRoot.getClass().newInstance();
        UIData restoredData = new UIData();
        UIDataAdaptor restoredAdaptor = new MockDataAdaptor();

        root.getChildren().add(restoredData);
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

            if (view.getAttributes().containsKey(COMPONENT_ADDED_AFTER_BUILD_VIEW))
            {
                ensureClearInitialState(view);
                states = new Object[]{
                            internalBuildTreeStructureToSave(view),
                            view.processSaveState(context)};
            }
            else
            {
                states = new HashMap<String, Object>();
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

        if (viewRoot.isTransient())
        {
            return null;
        }

        Object serializedComponentStates = viewRoot.processSaveState(facesContext);
        //Locale is a state attribute of UIViewRoot and need not be saved explicitly
        if (log.isLoggable(Level.FINEST)) log.finest("Exiting getComponentStateToSave");
        return serializedComponentStates;
    }
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

        if (viewRoot.isTransient())
        {
            return null;
        }

        Object serializedComponentStates = viewRoot.processSaveState(facesContext);
        //Locale is a state attribute of UIViewRoot and need not be saved explicitly
        return serializedComponentStates;
    }

    protected Object getTreeStructureToSave(FacesContext facesContext)
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

                Object rlcStates = !context.getResourceLibraryContracts().isEmpty() ?
                    UIComponentBase.saveAttachedState(context,
                                new ArrayList<String>(context.getResourceLibraryContracts())) : null;
                states = new Object[]{
                            internalBuildTreeStructureToSave(view),
                            view.processSaveState(context), rlcStates};
            }
            else
            {
                states = new HashMap<String, Object>();
View Full Code Here

Examples of javax.faces.component.UIViewRoot.processSaveState()

    {
      // if there's no stateManagementStrategy handle saving the state ourselves
      _removeTransientComponents(viewRoot);

      Object structure = !_needStructure(context) ? null : new Structure(viewRoot);
      Object state = viewRoot.processSaveState(context);
      viewState = new Object[]{structure, state};

    }

    if (_saveAsToken(context))
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.