Module jakarta.cdi

Interface EventContext<T>

  • Type Parameters:
    T - type of event object

    public interface EventContext<T>
    Represents a context of a fired event. Provides access to an event object and corresponding metadata.
    Since:
    2.0
    Author:
    Martin Kouba
    See Also:
    ObserverMethod.notify(EventContext), EventMetadata
    • Method Detail

      • getEvent

        T getEvent()
        Returns:
        the event object, aka the payload
      • getMetadata

        EventMetadata getMetadata()
        Returns:
        the event metadata