Package org.hibernate.resource.beans.spi
Interface ManagedBeanRegistry
-
- All Superinterfaces:
Serializable
,Service
- All Known Implementing Classes:
ManagedBeanRegistryImpl
public interface ManagedBeanRegistry extends Service
A registry forManagedBean
instances. Responsible for managing the lifecycle.Access to the beans and usage of them are only valid between the time the registry is initialized and released (however those events are recognized).
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <T> ManagedBean<T>
getBean(Class<T> beanClass)
Get a bean reference by class.<T> ManagedBean<T>
getBean(Class<T> beanContract, BeanInstanceProducer fallbackBeanInstanceProducer)
Get a bean reference by class with an explicit fallback bean instance producer.<T> ManagedBean<T>
getBean(String beanName, Class<T> beanContract)
Get a bean reference by name and contract.<T> ManagedBean<T>
getBean(String beanName, Class<T> beanContract, BeanInstanceProducer fallbackBeanInstanceProducer)
Get a bean reference by name and contract with an explicit fallback bean instance producer.BeanContainer
getBeanContainer()
Get a reference to the underlying BeanContainer.
-
-
-
Method Detail
-
getBean
<T> ManagedBean<T> getBean(Class<T> beanClass)
Get a bean reference by class.
-
getBean
<T> ManagedBean<T> getBean(String beanName, Class<T> beanContract)
Get a bean reference by name and contract.
-
getBean
<T> ManagedBean<T> getBean(Class<T> beanContract, BeanInstanceProducer fallbackBeanInstanceProducer)
Get a bean reference by class with an explicit fallback bean instance producer.
-
getBean
<T> ManagedBean<T> getBean(String beanName, Class<T> beanContract, BeanInstanceProducer fallbackBeanInstanceProducer)
Get a bean reference by name and contract with an explicit fallback bean instance producer.
-
getBeanContainer
BeanContainer getBeanContainer()
Get a reference to the underlying BeanContainer. May returnnull
indicating that no back-end container has been configured
-
-