org.springframework.beans.factory

Interface BeanFactoryAware

    • Method Detail

      • setBeanFactory

        void setBeanFactory(BeanFactory beanFactory)
                     throws BeansException
        Callback that supplies the owning factory to a bean instance.

        Invoked after the population of normal bean properties but before an initialization callback such as InitializingBean.afterPropertiesSet() or a custom init-method.

        Parameters:
        beanFactory - owning BeanFactory (never null). The bean can immediately call methods on the factory.
        Throws:
        BeansException - in case of initialization errors
        See Also:
        BeanInitializationException