Package javax.faces.event

Examples of javax.faces.event.PostConstructViewMapEvent


        fireAndAssert("13", new PostAddToViewEvent(component));
    }

    @Test
    public void testObservePostConstructViewMap() {
        fireAndAssert("14", new PostConstructViewMapEvent(uiViewRoot));
    }
View Full Code Here


        fireAndAssert("14", new PostConstructViewMapEvent(uiViewRoot));
    }

    @Test
    public void testObservePostConstructSpecificViewMap() {
        fireAndAssert("14a", new PostConstructViewMapEvent(uiViewRoot));
    }
View Full Code Here

  @SuppressWarnings("unchecked")
  public void processEvent(SystemEvent event) throws AbortProcessingException
  {
    if (event instanceof PostConstructViewMapEvent)
    {
      PostConstructViewMapEvent viewMapEvent = (PostConstructViewMapEvent) event;
      UIViewRoot viewRoot = (UIViewRoot) viewMapEvent.getComponent();
      viewRoot.getViewMap().put(ViewScope.VIEW_SCOPE_CALLBACKS,new HashMap<String, Runnable>());
    } else if (event instanceof PreDestroyViewMapEvent)
    {
      PreDestroyViewMapEvent viewMapEvent = (PreDestroyViewMapEvent) event;
      UIViewRoot viewRoot = (UIViewRoot) viewMapEvent.getComponent();
      Map<String, Runnable> callbacks = (Map<String, Runnable>) viewRoot.getViewMap().get(ViewScope.VIEW_SCOPE_CALLBACKS);
      if (callbacks != null)
      {
        for (Runnable c : callbacks.values())
        {
View Full Code Here

TOP

Related Classes of javax.faces.event.PostConstructViewMapEvent

Copyright © 2018 www.massapicom. 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.