Invoke all handlers with the given event as parameter.

@param eventProcessor
@param event the event
198796
public void process(EventPipeline eventPipeline, EventBase<?> event) {
        try {
            for (HandlerReference hdlr : this) {
                try {
                    hdlr.invoke(event);
                    if (event.isStopped()) {
                        break;
                    }
                } catch (AssertionError t) {
                    // JUnit support
                    CoreUtils.setAssertionError(t);
                    event.handlingError(eventPipeline, t);
                } catch (Error e) { // NOPMD
                    // Wouldn't have caught it, if it was possible.
                    throw e;
                } catch (Throwable t) { // NOPMD
                    // Errors have been rethrown, so this should work.
                    event.handlingError(eventPipeline, t);
                }
            }
        } finally { // NOPMD
            try {
                event.handled();
            } catch (AssertionError t) {
                // JUnit support
                CoreUtils.setAssertionError(t);
                event.handlingError(eventPipeline, t);
            } catch (Error e) { // NOPMD
                // Wouldn't have caught it, if it was possible.
                throw e;
            } catch (Throwable t) { // NOPMD
                // Errors have been rethrown, so this should work.
                event.handlingError(eventPipeline, t);
            }
        }
    }
718682
public void dispatchEvent(Event event, String eventName) {
    int typeInt = Event.getTypeInt(eventName);
    Object[] handlerData = $(element).data(EVENT_DATA);
    for (int i = 0, l = elementEvents.length(); i < l; i++) {
      BindFunction listener = elementEvents.get(i);
      String namespace = JsUtils.prop(event, "namespace");
      boolean matchEV = listener != null && (listener.hasEventType(typeInt) || listener.isTypeOf(eventName));
      boolean matchNS = matchEV && (isNullOrEmpty(namespace) || listener.nameSpace.equals(namespace));
      if (matchEV && matchNS) {
        if (!listener.fire(event, typeInt, eventName, handlerData)) {
          event.stopPropagation();
          event.preventDefault();
        }
      }
    }
  }
1065409
public void dispatchEvent(IEvent event) {
        for (IEventListener listener : listeners) {
            if (event.getSource() == null || event.getSource() != listener) {
                listener.notifyEvent(event);
            }
        }
    }
813368
@Override
    @SuppressWarnings("PMD.NcssCount")
    public void invoke(EventBase<?> event) throws Throwable {
        if (component == ComponentTree.DUMMY_HANDLER) {
            reportInvocation(event, false);
            return;
        }
        long invocation;
        switch (method.type().parameterCount()) {
        case 0:
            // No parameters
            invocation = reportInvocation(event, false);
            method.invoke();
            reportResult(event, invocation);
            break;

        case 1:
            // Event parameter
            invocation = reportInvocation(event, false);
            method.invoke(event);
            reportResult(event, invocation);
            break;

        case 2:
            // Event and channel
            Class<?> channelParam = method.type().parameterType(1);
            boolean handlerFound = false;
            for (Channel channel : event.channels()) {
                if (channelParam.isAssignableFrom(channel.getClass())) {
                    handlerFound = true;
                    invocation = reportInvocation(event, false);
                    method.invoke(event, channel);
                    reportResult(event, invocation);
                }
            }
            if (!handlerFound) {
                reportInvocation(event, true);
            }
            break;

        default:
            throw new IllegalStateException("Handle not usable");
        }
    }
980717
function handleEvent(namespace, attributeName, eventHandlerRegistry, event) {
    var target = event.target;
    var handlers = getHandlers(attributeName, eventHandlerRegistry, target);
    executeHandlers(handlers, event, namespace);
}
1325281
void executeHandlers(AuditEvent event) {
        String formattedEvent = configContext.getLayout().format(event);
        for (final Handler handler : configContext.getHandlers()) {
            handler.setAuditEvent(event);
            handler.setQuery(formattedEvent);
            try {
                handler.handle();
                handler.handle(event);
                handler.handle(formattedEvent);
            } catch (HandlerException e) {
                Log.warn("Failed to submit audit event.", e);
            }
        }
    }
1280472
public synchronized void insert_event(EventData event) {
        events.add(event);
        while (events.size() > max_size)
            events.remove(0);
    }
431846
private void handleEvent(PrimitiveEvent event) {
    log.trace("Received {}", event);
    Set<Consumer<PrimitiveEvent>> listeners = eventListeners.get(event.type());
    if (listeners != null) {
      listeners.forEach(l -> l.accept(event));
    }
  }
150688
@MainThread
    private void handleEventResult(Event event, EventResult result) {
        if (!activeEvents.contains(event)) {
            Utils.logE(event.getKey(), "Cannot send result of finished event");
            return;
        }

        scheduleResultCallbacks(event, result);
        executeTasks(false);
    }
232549
private void invokeMethods(Event event) {
        try {
            List<MethodWrapper> methodWrappers = eventToMethodsMap.get(event.getType().name().toUpperCase());
            if (methodWrappers == null) return;

            methodWrappers = new ArrayList<>(methodWrappers);
            MethodWrapper matchedMethod =
                    getMethodWithMatchingPatternAndFilterUnmatchedMethods(getPatternFromEventType(event), methodWrappers);
            if (matchedMethod != null) {
                methodWrappers = new ArrayList<>();
                methodWrappers.add(matchedMethod);
            }

            for (MethodWrapper methodWrapper : methodWrappers) {
                Method method = methodWrapper.getMethod();
                if (Arrays.asList(method.getParameterTypes()).contains(Matcher.class)) {
                    method.invoke(this, event, methodWrapper.getMatcher());
                } else {
                    method.invoke(this, event);
                }
            }
        } catch (Exception e) {
            logger.error("Error invoking controller: ", e);
        }
    }
1358090
@Override
    protected void handlingError(
            EventPipeline eventProcessor, Throwable throwable) {
        eventProcessor.fire(
            new HandlingError(this, throwable), channels());
    }
324131
public void invokeCallbacks(String eventName, T eventData) {
        String name = eventName;
        
        while (!StringUtils.isEmpty(name)) {
            Iterable<IGenericEvent<T>> subscribers = getSubscribers(name);
            
            if (subscribers != null) {
                for (IGenericEvent<T> subscriber : subscribers) {
                    try {
                        if (log.isDebugEnabled()) {
                            log.debug(String.format("Firing local Event[name=%s,data=%s]", eventName, eventData));
                        }
                        subscriber.eventCallback(eventName, eventData);
                    } catch (Throwable e) {
                        log.error("Error during local event callback.", e);
                    }
                }
            }
            
            name = stripLevel(name);
        }
    }
804075
protected function handle(Event $event)
    {
        $method = $this->getApplyMethod($event);
        if (!method_exists($this, $method)) {
            return;
        }
        $this->$method($event);
    }
718789
private void executeHandlers(List<Event> filteredEvents) {
        for (EventHandler current : eventHandlers) {
            for (Event event : filteredEvents) {
                current.handleEvent(event);
            }
        }
    }
315315
public void fireEvent(CmsEvent event) {

        fireEventHandler(m_eventListeners.get(event.getTypeInteger()), event);
        fireEventHandler(m_eventListeners.get(I_CmsEventListener.LISTENERS_FOR_ALL_EVENTS), event);
    }
222206
@Override
    public void handleEvent(Event event) {
        LOG.fine("CustomInfoHandler called");

        if (customInfo != null) {
            event.getCustomInfo().putAll(customInfo);
        }
    }
769719
final void performAction(final AbstractEventQueue eventQueue, final Event<?> event) {
        final Event<T> eventObject = (Event<T>) event;

        try {
            action(eventObject);
        } catch (final Exception e) {
            LOGGER.log(Level.WARN, "Event perform failed", e);
        } finally { // remove event from event queue
            if (eventQueue instanceof SynchronizedEventQueue) {
                final SynchronizedEventQueue synchronizedEventQueue = (SynchronizedEventQueue) eventQueue;

                synchronizedEventQueue.removeEvent(eventObject);
            }
        }
    }