Package javax.faces.lifecycle

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


            // if ProjectStage is Development, install the DebugPhaseListener
            FacesContext facesContext = FacesContext.getCurrentInstance();
            if (facesContext.isProjectStage(ProjectStage.Development) &&
                    MyfacesConfig.getCurrentInstance(facesContext.getExternalContext()).isDebugPhaseListenerEnabled())
            {
                lifecycle.addPhaseListener(new DebugPhaseListener());
            }
        }
    }

    /*
 
View Full Code Here


        for (Iterator iterator = getDispenser().getLifecyclePhaseListeners(); iterator.hasNext();)
        {
            String listenerClassName = (String) iterator.next();
            try
            {
                lifecycle.addPhaseListener((PhaseListener) ClassUtils.newInstance(listenerClassName));
            }
            catch (ClassCastException e)
            {
                log.error("Class " + listenerClassName + " does not implement PhaseListener");
            }
View Full Code Here

      // stored/managed by Faces -- we can merely render it
      if (context.getViewRoot() == null)
      {
        // add self as PhaseListener to prevent action phases from
        // executing
        lifecycle.addPhaseListener(this);
        try
        {
          lifecycle.execute(context);
        }
        catch (Exception e)
View Full Code Here

        Iterator lifecycleIds = lifecycleFactory.getLifecycleIds();
        while (lifecycleIds.hasNext())
        {
            currentId = (String) lifecycleIds.next();
            currentLifecycle = lifecycleFactory.getLifecycle(currentId);
            currentLifecycle.addPhaseListener(phaseListener);
        }
    }

    public static ResourceBundle getDefaultFacesMessageBundle(Locale locale)
    {
View Full Code Here

        Iterator lifecycleIds = lifecycleFactory.getLifecycleIds();
        while (lifecycleIds.hasNext())
        {
            currentId = (String) lifecycleIds.next();
            currentLifecycle = lifecycleFactory.getLifecycle(currentId);
            currentLifecycle.addPhaseListener(phaseListener);
        }
    }

    public static ResourceBundle getDefaultFacesMessageBundle(Locale locale)
    {
View Full Code Here

                    Object creationMetaData = getInjectionProvider().inject(listener);

                    injectedBeanStorage.add(new BeanEntry(listener, creationMetaData));

                    getInjectionProvider().postConstruct(listener, creationMetaData);
                    lifecycle.addPhaseListener(listener);
                }
                catch (ClassCastException e)
                {
                    log.severe("Class " + listenerClassName + " does not implement PhaseListener");
                }
View Full Code Here

            // if ProjectStage is Development, install the DebugPhaseListener
            FacesContext facesContext = getFacesContext();
            if (facesContext.isProjectStage(ProjectStage.Development) &&
                    MyfacesConfig.getCurrentInstance(facesContext.getExternalContext()).isDebugPhaseListenerEnabled())
            {
                lifecycle.addPhaseListener(new DebugPhaseListener());
            }
        }
    }

    /*
 
View Full Code Here

                    Object creationMetaData = getInjectionProvider().inject(listener);

                    injectedBeanStorage.add(new BeanEntry(listener, creationMetaData));

                    getInjectionProvider().postConstruct(listener, creationMetaData);
                    lifecycle.addPhaseListener(listener);
                }
                catch (ClassCastException e)
                {
                    log.severe("Class " + listenerClassName + " does not implement PhaseListener");
                }
View Full Code Here

            // if ProjectStage is Development, install the DebugPhaseListener
            FacesContext facesContext = getFacesContext();
            if (facesContext.isProjectStage(ProjectStage.Development) &&
                    MyfacesConfig.getCurrentInstance(facesContext.getExternalContext()).isDebugPhaseListenerEnabled())
            {
                lifecycle.addPhaseListener(new DebugPhaseListener());
            }
        }
    }

    /*
 
View Full Code Here

      // in case a prior scope was managed temporarily on the session -- remove it
      request.getPortletSession().removeAttribute(BRIDGE_PACKAGE_PREFIX + REQUEST_SCOPE_ID_RENDER_PARAM);
     
      // For actions we only execute the lifecycle phase

      lifecycle.addPhaseListener(this);
     
      lifecycle.execute(context);

      // If responseComplete don't save any state as we aren't falling through to render
      // Usual occurs because of a redirect
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.