Interface AfterTypeDiscovery


  • public interface AfterTypeDiscovery

    This event type is thrown by the container after type discovery is complete. If any observer method of the AfterTypeDiscovery event throws an exception, the exception is treated as a definition error by the container.

    Any observer of this event is permitted to add classes to, or remove classes from, the list of alternatives, list of interceptors or list of decorators. The container will use the final values of these lists, after all observers have been called, to determine the enabled alternatives, interceptors, and decorators for application. Changes made to these lists after the invocation of the last observer method of the AfterTypeDiscovery are ignored.

    CDI Lite implementations are not required to provide support for Portable Extensions.

    Since:
    1.1
    Author:
    Pete Muir, Antoine Sabot-Durand
    • Method Detail

      • getAlternatives

        List<Class<?>> getAlternatives()
        Returns:
        the list of enabled alternatives for the application, sorted by priority in ascending order. Alternatives enabled for a bean archive are not included.
        Throws:
        IllegalStateException - if called outside of the observer method invocation
      • getInterceptors

        List<Class<?>> getInterceptors()
        Returns:
        the list of enabled interceptors for the application, sorted by priority in ascending order. Interceptors enabled for a bean archive are not included.
        Throws:
        IllegalStateException - if called outside of the observer method invocation
      • getDecorators

        List<Class<?>> getDecorators()
        Returns:
        the list of enabled decorators for the application, sorted by priority in ascending order. Decorators enabled for a bean archive are not included.
        Throws:
        IllegalStateException - if called outside of the observer method invocation