Examples of XmlBeanDefinitionReader


Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

        return null;
    }

    public ApplicationContext enrichedContext() throws IOException {
        GenericApplicationContext that=new GenericApplicationContext(applicationContext);
        XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(that);
        reader.setValidationMode(XmlBeanDefinitionReader.VALIDATION_XSD);
        reader.loadBeanDefinitions(new InputStreamResource(getContextXml()));
        that.refresh();
        return that;
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

        this.servletContext.setAttribute(WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE, context);
        context.setServletContext(this.servletContext);
    }

    protected void loadBeanDefinitions(GenericWebApplicationContext context, String[] locations) {
        new XmlBeanDefinitionReader(context).loadBeanDefinitions(locations);
        AnnotationConfigUtils.registerAnnotationConfigProcessors(context);
        context.refresh();
        context.registerShutdownHook();
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

    return create(null);
  }

  public static ParserContext create(BeanDefinitionParserDelegate delegate) {
    DefaultListableBeanFactory beanFactory = new DefaultListableBeanFactory();
    XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(beanFactory);
    XmlReaderContext readerContext = new XmlReaderContext(null, null, null, null, reader,
        null);
    return new ParserContext(readerContext, delegate);
  }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

    private GenericApplicationContext applicationContext;
   
   
       
    private void readBeans(Resource beanResource) {
        XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(applicationContext);
        reader.loadBeanDefinitions(beanResource);
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

       
        if (is != null) {
            LOG.log(Level.INFO, "BUILD_ENDPOINTS_FROM_CONFIG_LOCATION", new Object[]{location});
            childCtx = new GenericApplicationContext(ctx);
           
            XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(childCtx);
            reader.setValidationMode(XmlBeanDefinitionReader.VALIDATION_XSD);
            reader.loadBeanDefinitions(new InputStreamResource(is, location));
           
            childCtx.refresh();
        }
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

    private GenericApplicationContext applicationContext;
   
   
       
    private void readBeans(Resource beanResource) {
        XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(applicationContext);
        reader.loadBeanDefinitions(beanResource);
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

        this.webContext = new GenericWebApplicationContext();

        this.servletContext.setAttribute(ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE, this.webContext);
        this.webContext.setServletContext(this.servletContext);

        new XmlBeanDefinitionReader(this.webContext).loadBeanDefinitions(locations);
        AnnotationConfigUtils.registerAnnotationConfigProcessors(this.webContext);
        this.webContext.refresh();
        this.webContext.registerShutdownHook();

        return this.webContext;
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

       
        if (is != null) {
            LOG.log(Level.INFO, "BUILD_ENDPOINTS_FROM_CONFIG_LOCATION", new Object[]{location});
            childCtx = new GenericApplicationContext(ctx);
           
            XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(childCtx);
            reader.setValidationMode(XmlBeanDefinitionReader.VALIDATION_XSD);
            reader.loadBeanDefinitions(new InputStreamResource(is, location));
           
            childCtx.refresh();
        }
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

    private GenericApplicationContext applicationContext;
   
   
       
    private void readBeans(Resource beanResource) {
        XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(applicationContext);
        reader.loadBeanDefinitions(beanResource);
    }
View Full Code Here

Examples of org.springframework.beans.factory.xml.XmlBeanDefinitionReader

            return;
        }
        applicationContext = new GenericApplicationContext();
        resourceLoader = new DefaultResourceLoader(configContextClass.getClassLoader());
        for (String beanDefinitionPath : getConfigLocations()) {
            XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(applicationContext);
            Resource resource = resourceLoader.getResource(beanDefinitionPath);
            reader.loadBeanDefinitions(resource);
        }
        additionalSpringConfiguration(applicationContext);
        applicationContext.refresh();
        super.setUpBus();
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.