Java 类javax.enterprise.inject.se.SeContainer 实例源码

项目:reactive-cdi-events    文件:Main.java   
public static void main(String[] args) {
    SeContainer seContainer = SeContainerInitializer.newInstance()
            .disableDiscovery()
            .addExtensions(new ReactorExtension())
            .addBeanClasses(FooBarBean.class, EventReceiver.class)
            .initialize();
    FooBarBean bean = seContainer.select(FooBarBean.class).get();
    bean.fluxTheCapacitor();
}
项目:ee8-sandbox    文件:GreeterTest.java   
@Test
public void bootBasicContainer() {
    SeContainerInitializer initializer = SeContainerInitializer.newInstance();
    try (SeContainer container = initializer.initialize()) {
        assertTrue(container.isRunning());
        Set<Bean<?>> greeters = container.getBeanManager().getBeans("greeter");
        assertTrue(greeters.size() == 1);
    }
}
项目:hammock    文件:Weld3Bootstrapper.java   
public SeContainer getSeContainer() {
    return seContainer;
}