Package javax.faces.lifecycle

Examples of javax.faces.lifecycle.Lifecycle.execute()


      // add self as PhaseListener to prevent action phase from executing (after restoreView)
      Lifecycle lifecycle = getLifecycle();
      lifecycle.addPhaseListener(this);

      // For actions we only execute the lifecycle phase
      lifecycle.execute(context);
     
      // call the eventhandler to process
      EventNavigationResult result = mEventHandler.handleEvent(context, request.getEvent());
     
      if (result != null)
View Full Code Here


                        // certain tweaks have to be made to the FacesContext to allow
                        // us to reset the lifecycle
                        Lifecycle lifecycle = getLifecycle(context);
                        instrumentedContext = new InstrumentedFacesContext(context);
                        instrumentedContext.pushViewIntoRequestMap().clearViewRoot().clearPostback().set();
                        lifecycle.execute(instrumentedContext);
                        instrumentedContext.restore();

                        /*
                         * Another approach would be to register a phase listener in the decode() method for the phase in which
                         * the action is set to invoke. The phase listener would performs a servlet forward if a non-redirect
View Full Code Here

      this.facesContext.setViewRoot(viewRoot);
    } else {
      this.rendering = modelAndViewArtifact;
      try {
        Lifecycle lifecycle = this.lifecycleAccessor.getLifecycle();
        lifecycle.execute(context);
        lifecycle.render(context);
      } finally {
        this.rendering = null;
      }
    }
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.