Interface BeanCreatedEventListener<T>

  • Type Parameters:
    T - The event type
    All Superinterfaces:
    java.util.EventListener
    Functional Interface:
    This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

    @Indexed(BeanCreatedEventListener.class)
    @FunctionalInterface
    public interface BeanCreatedEventListener<T>
    extends java.util.EventListener

    An event listener that is triggered each time a bean is created.

    Allows customization of the created beans.

    Since:
    1.0
    See Also:
    BeanCreatedEvent
    • Method Detail

      • onCreated

        T onCreated​(@NonNull
                    BeanCreatedEvent<T> event)
        Fired when a bean is created and all PostConstruct initialization hooks have been called.
        Parameters:
        event - The bean created event
        Returns:
        The bean or a replacement bean of the same type