Package org.impalaframework.module.loader

Examples of org.impalaframework.module.loader.BeansetApplicationModuleLoader


    assertFalse(child.containsBean("importedBean2"));
  }
 
  public final void testNewBeanDefinitionReader() {
    BeansetModuleDefinition definition = new SimpleBeansetModuleDefinition(plugin4);
    BeansetApplicationModuleLoader loader = new BeansetApplicationModuleLoader();
 
    XmlBeanDefinitionReader reader = loader.newBeanDefinitionReader("id", new GenericApplicationContext(), definition);
    int definitions = reader.loadBeanDefinitions(new ClassPathResource("parentTestContext.xml"));
    assertTrue(definitions > 0);
  }
View Full Code Here


    assertTrue(definitions > 0);
  }

  private void loadChild(BeansetModuleDefinition definition) {
    parent = new ClassPathXmlApplicationContext("parentTestContext.xml");
    BeansetApplicationModuleLoader moduleLoader = new BeansetApplicationModuleLoader();
    ClassLoader classLoader = ClassUtils.getDefaultClassLoader();
    child = moduleLoader.newApplicationContext(null, parent, definition, classLoader);
    XmlBeanDefinitionReader xmlReader = moduleLoader.newBeanDefinitionReader("id", child, definition);
    xmlReader.setBeanClassLoader(classLoader);
    xmlReader.loadBeanDefinitions(moduleLoader.getSpringConfigResources("id", definition, classLoader));
    child.refresh();
  }
View Full Code Here

      registry.setModuleLoader(ModuleTypes.ROOT, new ManualReloadingRootModuleLoader(moduleLocationResolver));
    else
      registry.setModuleLoader(ModuleTypes.ROOT, new SystemRootModuleLoader(moduleLocationResolver));

    registry.setModuleLoader(ModuleTypes.APPLICATION, new ApplicationModuleLoader(moduleLocationResolver));
    registry.setModuleLoader(ModuleTypes.APPLICATION_WITH_BEANSETS, new BeansetApplicationModuleLoader(
        moduleLocationResolver));
  }
View Full Code Here

TOP

Related Classes of org.impalaframework.module.loader.BeansetApplicationModuleLoader

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.