public WeldBootstrapService(final WeldDeployment deployment, final Environment environment, final String deploymentName,
final Consumer<WeldBootstrapService> weldBootstrapServiceConsumer,
final Supplier<ExecutorServices> executorServicesSupplier,
final Supplier<ExecutorService> serverExecutorSupplier,
final Supplier<SecurityServices> securityServicesSupplier,
final Supplier<TransactionServices> weldTransactionServicesSupplier
) {
this.deployment = deployment;
this.environment = environment;
this.deploymentName = deploymentName;
this.weldBootstrapServiceConsumer = weldBootstrapServiceConsumer;
this.executorServicesSupplier = executorServicesSupplier;
this.serverExecutorSupplier = serverExecutorSupplier;
this.securityServicesSupplier = securityServicesSupplier;
this.weldTransactionServicesSupplier = weldTransactionServicesSupplier;
this.bootstrap = new WeldBootstrap();
Map<String, BeanDeploymentArchive> bdas = new HashMap<String, BeanDeploymentArchive>();
BeanDeploymentArchiveImpl rootBeanDeploymentArchive = null;
for (BeanDeploymentArchive archive : deployment.getBeanDeploymentArchives()) {
bdas.put(archive.getId(), archive);
if (archive instanceof BeanDeploymentArchiveImpl) {
BeanDeploymentArchiveImpl bda = (BeanDeploymentArchiveImpl) archive;
if (bda.isRoot()) {
rootBeanDeploymentArchive = bda;
}
}
}
this.rootBeanDeploymentArchive = rootBeanDeploymentArchive;
this.beanDeploymentArchives = Collections.unmodifiableMap(bdas);
}