use of org.jboss.as.weld.ejb.WeldInterceptorBindingsService in project wildfly by wildfly.
the class WeldComponentIntegrationProcessor method addWeldInterceptorBindingService.
private static ServiceName addWeldInterceptorBindingService(final ServiceTarget target, final ComponentConfiguration configuration, final Class<?> componentClass, final String beanName, final ServiceName weldServiceName, final ServiceName weldStartService, final String beanDeploymentArchiveId, final ComponentInterceptorSupport componentInterceptorSupport) {
ServiceName bindingServiceName = configuration.getComponentDescription().getServiceName().append(WeldInterceptorBindingsService.SERVICE_NAME);
final ServiceBuilder<?> sb = target.addService(bindingServiceName);
final Consumer<InterceptorBindings> interceptorBindingsConsumer = sb.provides(bindingServiceName);
final Supplier<WeldBootstrapService> weldContainerSupplier = sb.requires(weldServiceName);
sb.requires(weldStartService);
sb.setInstance(new WeldInterceptorBindingsService(interceptorBindingsConsumer, weldContainerSupplier, beanDeploymentArchiveId, beanName, componentClass, componentInterceptorSupport));
sb.install();
return bindingServiceName;
}
Aggregations