Package org.impalaframework.module.beanset

Examples of org.impalaframework.module.beanset.RecordingImportingBeanDefinitionDocumentReader


  }

  protected GenericApplicationContext createContext(final Properties properties, String expectedResource) {
    GenericApplicationContext context = new GenericApplicationContext();
   
    final RecordingImportingBeanDefinitionDocumentReader documentReader = new RecordingImportingBeanDefinitionDocumentReader(properties);

    XmlBeanDefinitionReader xmlReader = new XmlBeanDefinitionReader(context){
      @Override
      protected BeanDefinitionDocumentReader createBeanDefinitionDocumentReader() {
        return documentReader;
      }
    };

    xmlReader.loadBeanDefinitions(new ClassPathResource("beanset/beanset-context.xml"));
    List<BeanSetNode> nodes = documentReader.getTopLevelNodes();
   
    System.out.println(documentReader);
   
    assertEquals(1, nodes.size());
    final BeanSetNode topLevel = nodes.get(0);
View Full Code Here


      ClassLoader classLoader = context.getClassLoader();

      Properties properties = new BeanSetPropertiesReader().readBeanSetDefinition(classLoader, overrides);     
     
      final ConfigurableListableBeanFactory beanFactory = context.getBeanFactory();
      final RecordingImportingBeanDefinitionDocumentReader documentReader = new RecordingImportingBeanDefinitionDocumentReader(properties);

      XmlBeanDefinitionReader xmlReader = new XmlBeanDefinitionReader(ModuleUtils.castToBeanDefinitionRegistry(beanFactory)){
        protected BeanDefinitionDocumentReader createBeanDefinitionDocumentReader() {
          return documentReader;
        }
View Full Code Here

      ClassLoader classLoader = context.getClassLoader();

      Properties properties = new BeanSetPropertiesReader().readBeanSetDefinition(classLoader, overrides);     
     
      final ConfigurableListableBeanFactory beanFactory = context.getBeanFactory();
      final RecordingImportingBeanDefinitionDocumentReader documentReader = new RecordingImportingBeanDefinitionDocumentReader(properties);

      XmlBeanDefinitionReader xmlReader = new XmlBeanDefinitionReader(ModuleUtils.castToBeanDefinitionRegistry(beanFactory)){
        protected BeanDefinitionDocumentReader createBeanDefinitionDocumentReader() {
          return documentReader;
        }
View Full Code Here

TOP

Related Classes of org.impalaframework.module.beanset.RecordingImportingBeanDefinitionDocumentReader

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.