Examples of visitTree()


Examples of javax.faces.component.UIComponent.visitTree()

                try
                {
                    facesContext.getAttributes().put(SKIP_ITERATION_HINT, Boolean.TRUE);

                    VisitContext visitContext = VisitContext.createVisitContext(facesContext, null, VISIT_HINTS);
                    facet.visitTree(visitContext, new RefreshViewContext());
                }
                finally
                {
                    // We must remove hint in finally, because an exception can break this phase,
                    // but lifecycle can continue, if custom exception handler swallows the exception
View Full Code Here

Examples of javax.faces.component.UIComponent.visitTree()

                try
                {
                    facesContext.getAttributes().put(SKIP_ITERATION_HINT, Boolean.TRUE);

                    VisitContext visitContext = VisitContext.createVisitContext(facesContext, null, VISIT_HINTS);
                    facet.visitTree(visitContext, new RefreshViewContext());
                }
                finally
                {
                    // We must remove hint in finally, because an exception can break this phase,
                    // but lifecycle can continue, if custom exception handler swallows the exception
View Full Code Here

Examples of javax.faces.component.UIComponent.visitTree()

                try
                {
                    facesContext.getAttributes().put(SKIP_ITERATION_HINT, Boolean.TRUE);

                    VisitContext visitContext = VisitContext.createVisitContext(facesContext, null, null);
                    facet.visitTree(visitContext, new RefreshViewContext());
                }
                finally
                {
                    // We must remove hint in finally, because an exception can break this phase,
                    // but lifecycle can continue, if custom exception handler swallows the exception
View Full Code Here

Examples of javax.faces.component.UIComponent.visitTree()

                try
                {
                    facesContext.getAttributes().put(SKIP_ITERATION_HINT, Boolean.TRUE);

                    VisitContext visitContext = VisitContext.createVisitContext(facesContext, null, VISIT_HINTS);
                    facet.visitTree(visitContext, new RefreshViewContext());
                }
                finally
                {
                    // We must remove hint in finally, because an exception can break this phase,
                    // but lifecycle can continue, if custom exception handler swallows the exception
View Full Code Here

Examples of javax.faces.component.UIComponent.visitTree()

                        while (i < end && _isIndexAvailable())
                        {
                            for (int j = 0, childCount = getChildCount(); j < childCount; j++)
                            {
                                UIComponent child = getChildren().get(j);
                                if (child.visitTree(context, callback))
                                {
                                    return true;
                                }
                            }
                           
View Full Code Here

Examples of javax.faces.component.UIComponent.visitTree()

      // children.
      for (Iterator<UIComponent> iter = parentComponent.getFacetsAndChildren(); iter.hasNext();)
      {
        UIComponent child = iter.next();

        if (child.visitTree(visitContext, callback))
        {
          return true;
        }
      }
View Full Code Here

Examples of javax.faces.component.UIData.visitTree()

    int originalRows = table.getRows();
    table.setRows(0); // We want to visit all rows.

    FacesContext context = FacesContext.getCurrentInstance();
    UniqueColumnValueChecker checker = new UniqueColumnValueChecker(table, input);
    table.visitTree(VisitContext.createVisitContext(context), checker);
    table.setRows(originalRows);

    if (checker.isDuplicate()) {
      input.setValid(false);
      context.validationFailed();
View Full Code Here

Examples of javax.faces.component.UIForm.visitTree()

        if (command instanceof HtmlCommandButton)
        {
            final FacesContext facesContext = testCase.getFacesContext();
            UIForm form = getParentForm(command);
            VisitContext visitContext = VisitContext.createVisitContext(facesContext);
            form.visitTree(visitContext, new VisitCallback(){

                public VisitResult visit(VisitContext context,
                        UIComponent target)
                {
                    if (target instanceof UIInput)
View Full Code Here

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

        //TODO ask the EG the this is a spec violation if we do it that way
        //see Section 2.2.1

        //context.setProcessingEvents(true);
        //try {
            view.visitTree(VisitContext.createVisitContext(context), new RestoreStateCallback());
        //} finally {
        //    context.setProcessingEvents(oldContextEventState);
        //}
        return view;
    }
View Full Code Here

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

            // during state saving.  It should be removed at some point.
            facesContext.getAttributes().put(SKIP_ITERATION_HINT, true);

            Set<VisitHint> hints = EnumSet.of(VisitHint.SKIP_ITERATION);
            VisitContext visitContext = VisitContext.createVisitContext(facesContext, null, hints);
            root.visitTree(visitContext, new VisitCallback() {

                        public VisitResult visit(VisitContext context, UIComponent target) {
                            postRestoreStateEvent.setComponent(target);
                            target.processEvent(postRestoreStateEvent);
                            //noinspection ReturnInsideFinallyBlock
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.