public class IOCSingletonBean<T> extends IOCDependentBean<T>
beanManager, beanProvider
beanType, concrete, name, qualifiers, type
Modifier and Type | Method and Description |
---|---|
T |
getInstance()
Returns an instance of the bean within the active scope.
|
T |
getInstance(CreationalContext context)
Returns an instance of the bean within the active scope, using the specified
SimpleCreationalContext.
|
Class<? extends Annotation> |
getScope()
Returns the scope of the bean.
|
static <T> IOCBeanDef<T> |
newBean(SyncBeanManagerImpl beanManager,
Class<T> type,
Class<?> beanType,
Annotation[] qualifiers,
String name,
boolean concrete,
BeanProvider<T> callback,
T instance,
Class<Object> beanActivatorType)
Creates a new IOC Bean reference
|
String |
toString() |
isActivated, newBean, newInstance
getBeanClass, getName, getQualifiers, getType, isConcrete, matches
public static <T> IOCBeanDef<T> newBean(SyncBeanManagerImpl beanManager, Class<T> type, Class<?> beanType, Annotation[] qualifiers, String name, boolean concrete, BeanProvider<T> callback, T instance, Class<Object> beanActivatorType)
T
- The type of the beantype
- The type of a beanqualifiers
- The qualifiers of the bean.name
- The name of the beaninstance
- The instance of the bean.activator
- The bean activator to use, may be null.public T getInstance(CreationalContext context)
IOCBeanDef
getInstance
in interface IOCBeanDef<T>
getInstance
in class IOCDependentBean<T>
public T getInstance()
IOCBeanDef
getInstance
in interface IOCBeanDef<T>
getInstance
in class IOCDependentBean<T>
public Class<? extends Annotation> getScope()
IOCBeanDef
getScope
in interface IOCBeanDef<T>
getScope
in class IOCDependentBean<T>
public String toString()
toString
in class AbstractIOCBean<T>
Copyright © 2013-2015 JBoss, a division of Red Hat. All Rights Reserved.