Package org.jboss.weld
Class SimpleCDI
- java.lang.Object
-
- javax.enterprise.inject.spi.CDI<T>
-
- org.jboss.weld.AbstractCDI<Object>
-
- org.jboss.weld.SimpleCDI
-
- All Implemented Interfaces:
Iterable<Object>,Instance<Object>,Provider<Object>,WeldInstance<Object>
public class SimpleCDI extends AbstractCDI<Object>
Provides convenient way to access the CDI container.- Author:
- Jozef Hartinger
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.jboss.weld.inject.WeldInstance
WeldInstance.Handler<T>
-
-
Field Summary
-
Fields inherited from class org.jboss.weld.AbstractCDI
knownClassNames
-
Fields inherited from class javax.enterprise.inject.spi.CDI
configuredProvider, discoveredProviders
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected BeanManagerImplambiguousBeanManager(String callerClassName, Set<BeanManagerImpl> managers)Callback that allows to override the behavior when class that invoked CDI.current() is placed in multiple bean archives.voidcleanup()BeanManagerProxygetBeanManager()Get the CDI BeanManager for the current contextprotected ContainergetContainer()StringtoString()protected BeanManagerImplunsatisfiedBeanManager(String callerClassName)Callback that allows to override the behavior when CDI.current() is not called from within a bean archive.-
Methods inherited from class org.jboss.weld.AbstractCDI
checkState, destroy, get, getCallingClassName, getHandler, getInstance, getPriorityComparator, handlers, isAmbiguous, isResolvable, isUnsatisfied, iterator, select, select, select, select
-
Methods inherited from class javax.enterprise.inject.spi.CDI
current, setCDIProvider
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Methods inherited from interface org.jboss.weld.inject.WeldInstance
handlersStream
-
-
-
-
Constructor Detail
-
SimpleCDI
public SimpleCDI()
-
SimpleCDI
public SimpleCDI(Container container)
-
-
Method Detail
-
unsatisfiedBeanManager
protected BeanManagerImpl unsatisfiedBeanManager(String callerClassName)
Callback that allows to override the behavior when CDI.current() is not called from within a bean archive.
-
ambiguousBeanManager
protected BeanManagerImpl ambiguousBeanManager(String callerClassName, Set<BeanManagerImpl> managers)
Callback that allows to override the behavior when class that invoked CDI.current() is placed in multiple bean archives.
-
getBeanManager
public BeanManagerProxy getBeanManager()
Description copied from class:CDIGet the CDI BeanManager for the current context- Specified by:
getBeanManagerin classCDI<Object>- Returns:
- the BeanManager
-
getContainer
protected Container getContainer()
-
cleanup
public void cleanup()
-
-