@Override
    public VisitResult visit(VisitContext context, UIComponent target) {

        if (target instanceof AjaxExceptionHandler) {
            AjaxExceptionHandler currentHandler = (AjaxExceptionHandler) target;

            if (LangUtils.isBlank(currentHandler.getType())) {
                handlers.put(null, currentHandler);
            }
            else {
                handlers.put(currentHandler.getType(), currentHandler);

                // exact type matched - we don't need to search more generic handlers
                if (throwable.getClass().getName().equals(currentHandler.getType())) {
                    return VisitResult.COMPLETE;
                }
            }
        }
        else if (target instanceof UIData) {
            return VisitResult.REJECT;
        }

        return VisitResult.ACCEPT;
    }
{@link VisitCallback} which collects all {@link AjaxExceptionHandler}s.
primefaces/src/main/java/org/primefaces/component/ajaxexceptionhandler/AjaxExceptionHandlerVisitCallback.java