org.jboss.weld.environment.servlet.deployment.ServletDeployment Maven / Gradle / Ivy
package org.jboss.weld.environment.servlet.deployment;
import java.util.ArrayList;
import java.util.Collection;
import javax.servlet.ServletContext;
import org.jboss.weld.bootstrap.api.ServiceRegistry;
import org.jboss.weld.bootstrap.api.helpers.SimpleServiceRegistry;
import org.jboss.weld.bootstrap.spi.BeanDeploymentArchive;
import org.jboss.weld.bootstrap.spi.Deployment;
public class ServletDeployment implements Deployment
{
private final WebAppBeanDeploymentArchive webAppBeanDeploymentArchive;
private final Collection beanDeploymentArchives;
private final ServiceRegistry services;
public ServletDeployment(ServletContext servletContext)
{
this.webAppBeanDeploymentArchive = new WebAppBeanDeploymentArchive(servletContext);
this.beanDeploymentArchives = new ArrayList();
this.beanDeploymentArchives.add(webAppBeanDeploymentArchive);
this.services = new SimpleServiceRegistry();
}
public Collection getBeanDeploymentArchives()
{
return beanDeploymentArchives;
}
public ServiceRegistry getServices()
{
return services;
}
public BeanDeploymentArchive loadBeanDeploymentArchive(Class> beanClass)
{
return webAppBeanDeploymentArchive;
}
public WebAppBeanDeploymentArchive getWebAppBeanDeploymentArchive()
{
return webAppBeanDeploymentArchive;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy