Example usage for org.springframework.web.context.support AnnotationConfigWebApplicationContext setNamespace

List of usage examples for org.springframework.web.context.support AnnotationConfigWebApplicationContext setNamespace

Introduction

In this page you can find the example usage for org.springframework.web.context.support AnnotationConfigWebApplicationContext setNamespace.

Prototype

@Override
    public void setNamespace(@Nullable String namespace) 

Source Link

Usage

From source file:org.lightadmin.logging.configurer.LightConfigurerWebApplicationInitializer.java

private AnnotationConfigWebApplicationContext createApplicationContext() {
    AnnotationConfigWebApplicationContext webApplicationContext = new AnnotationConfigWebApplicationContext();
    webApplicationContext.register(configurations());
    webApplicationContext.setDisplayName("LightConfigurer WebApplicationContext");
    webApplicationContext.setNamespace("light-configurer");
    return webApplicationContext;
}

From source file:org.lightadmin.core.config.LightAdminWebApplicationInitializer.java

private AnnotationConfigWebApplicationContext lightAdminApplicationContext(
        final ServletContext servletContext) {
    AnnotationConfigWebApplicationContext webApplicationContext = new AnnotationConfigWebApplicationContext();

    String basePackage = configurationsBasePackage(servletContext);
    webApplicationContext.register(configurations(servletContext));
    webApplicationContext.addBeanFactoryPostProcessor(
            new LightAdminBeanDefinitionRegistryPostProcessor(basePackage, servletContext));

    webApplicationContext.setDisplayName("LightAdmin WebApplicationContext");
    webApplicationContext.setNamespace("lightadmin");
    return webApplicationContext;
}