Example usage for org.springframework.beans.factory.config ConfigurableListableBeanFactory getRegisteredScope

List of usage examples for org.springframework.beans.factory.config ConfigurableListableBeanFactory getRegisteredScope

Introduction

In this page you can find the example usage for org.springframework.beans.factory.config ConfigurableListableBeanFactory getRegisteredScope.

Prototype

@Nullable
Scope getRegisteredScope(String scopeName);

Source Link

Document

Return the Scope implementation for the given scope name, if any.

Usage

From source file:com.github.persapiens.jsfboot.annotations.JsfCdiToSpringApplicationBeanFactoryPostProcessorIT.java

public void testRegisteredScopeView() {
    ConfigurableListableBeanFactory beanFactory = new DefaultListableBeanFactory();
    BeanFactoryPostProcessor beanFactoryPostProcessor = new JsfCdiToSpringBeanFactoryPostProcessor();

    beanFactoryPostProcessor.postProcessBeanFactory(beanFactory);

    assertThat(beanFactory.getRegisteredScope("view")).isInstanceOf(ViewScope.class);
}

From source file:org.joinfaces.annotations.JsfCdiToSpringApplicationBeanFactoryPostProcessorIT.java

@Test
public void testRegisteredScopeView() {
    ConfigurableListableBeanFactory beanFactory = new DefaultListableBeanFactory();
    BeanFactoryPostProcessor beanFactoryPostProcessor = new JsfCdiToSpringBeanFactoryPostProcessor();

    beanFactoryPostProcessor.postProcessBeanFactory(beanFactory);

    assertThat(beanFactory.getRegisteredScope(JsfCdiToSpring.VIEW)).isInstanceOf(ViewScope.class);
}