Class CDI<T>

    • Field Detail

      • discoveredProviders

        protected static volatile Set<CDIProvider> discoveredProviders
      • configuredProvider

        protected static volatile CDIProvider configuredProvider
    • Constructor Detail

      • CDI

        public CDI()
    • Method Detail

      • current

        public static CDI<Object> current()

        Get the CDI instance that provides access to the current container.

        If there are no providers available, an IllegalStateException is thrown, otherwise the first provider which can access the container is used.

        Returns:
        the CDI instance
        Throws:
        IllegalStateException - if no CDIProvider is available
      • getBeanManager

        public abstract BeanManager getBeanManager()
        Get the CDI BeanManager for the current context
        Returns:
        the BeanManager