Search in sources :

Example 1 with BeanFactoryLocator

use of org.springframework.beans.factory.access.BeanFactoryLocator in project simba-os by cegeka.

the class SpringAwareLocator method getApplicationContext.

private ApplicationContext getApplicationContext() {
    if (context == null) {
        BeanFactoryLocator locator = ContextSingletonBeanFactoryLocator.getInstance(contextConfigLocation);
        BeanFactoryReference reference = locator.useBeanFactory("simbaContext");
        context = (AbstractApplicationContext) reference.getFactory();
    }
    return context;
}
Also used : BeanFactoryReference(org.springframework.beans.factory.access.BeanFactoryReference) ContextSingletonBeanFactoryLocator(org.springframework.context.access.ContextSingletonBeanFactoryLocator) BeanFactoryLocator(org.springframework.beans.factory.access.BeanFactoryLocator)

Example 2 with BeanFactoryLocator

use of org.springframework.beans.factory.access.BeanFactoryLocator in project sakuli by ConSol.

the class BeanLoader method getBeanFactory.

private static BeanFactory getBeanFactory() {
    BeanFactoryLocator bfl = SingletonBeanFactoryLocator.getInstance(CONTEXT_PATH);
    bfl.useBeanFactory("org.sakuli.app.root");
    return getBeanFactoryReference().getFactory();
}
Also used : SingletonBeanFactoryLocator(org.springframework.beans.factory.access.SingletonBeanFactoryLocator) BeanFactoryLocator(org.springframework.beans.factory.access.BeanFactoryLocator)

Aggregations

BeanFactoryLocator (org.springframework.beans.factory.access.BeanFactoryLocator)2 BeanFactoryReference (org.springframework.beans.factory.access.BeanFactoryReference)1 SingletonBeanFactoryLocator (org.springframework.beans.factory.access.SingletonBeanFactoryLocator)1 ContextSingletonBeanFactoryLocator (org.springframework.context.access.ContextSingletonBeanFactoryLocator)1