Example usage for org.springframework.beans.factory.xml XmlBeanDefinitionReader setNamespaceAware

List of usage examples for org.springframework.beans.factory.xml XmlBeanDefinitionReader setNamespaceAware

Introduction

In this page you can find the example usage for org.springframework.beans.factory.xml XmlBeanDefinitionReader setNamespaceAware.

Prototype

public void setNamespaceAware(boolean namespaceAware) 

Source Link

Document

Set whether or not the XML parser should be XML namespace aware.

Usage

From source file:technology.tikal.gae.optimization.CustomXmlWebApplicationContext.java

protected void initBeanDefinitionReader(XmlBeanDefinitionReader beanDefinitionReader) {
    super.initBeanDefinitionReader(beanDefinitionReader);
    if (SystemProperty.environment.value() == SystemProperty.Environment.Value.Production) {
        beanDefinitionReader.setValidating(false);
        beanDefinitionReader.setNamespaceAware(true);
    }// w  ww .  ja  va  2s .c  om
}

From source file:org.nekorp.workflow.backend.optimization.CustomXmlWebApplicationContext.java

protected void initBeanDefinitionReader(XmlBeanDefinitionReader beanDefinitionReader) {
    super.initBeanDefinitionReader(beanDefinitionReader);
    if (SystemProperty.environment.value() == SystemProperty.Environment.Value.Production) {
        beanDefinitionReader.setValidationMode(XmlBeanDefinitionReader.VALIDATION_NONE);
        beanDefinitionReader.setNamespaceAware(true);
    }/* www . jav a2 s  .  c  om*/
}

From source file:org.nebulaframework.util.spring.NebulaApplicationContext.java

/**
 * Initialize the bean definition reader used for loading the bean
 * definitions of this context, and disabled XSD Validation to speed up the
 * context start up time.//w ww  .  ja v a2  s  . c om
 */
@Override
protected void initBeanDefinitionReader(XmlBeanDefinitionReader beanDefinitionReader) {
    beanDefinitionReader.setValidationMode(XmlBeanDefinitionReader.VALIDATION_NONE);
    beanDefinitionReader.setNamespaceAware(true);
}

From source file:org.solmix.runtime.support.spring.ContainerApplicationContext.java

@Override
protected void initBeanDefinitionReader(XmlBeanDefinitionReader reader) {
    // Spring always creates a new one of these, which takes a fair amount
    // of time on startup (nearly 1/2 second) as it gets created for every
    // spring context on the classpath
    if (nshResolver == null) {
        nshResolver = new DefaultNamespaceHandlerResolver();
    }/*from ww w. j a va2 s  .c o m*/
    reader.setNamespaceHandlerResolver(nshResolver);

    String mode = getSpringValidationMode();
    if (null != mode) {
        reader.setValidationModeName(mode);
    }
    reader.setNamespaceAware(true);

    setEntityResolvers(reader);
}