for (Entry<Class<? extends Service>, Service> entry : serviceRegistry.entrySet()) { if (!newBdaServices.contains(entry.getKey())) { newBdaServices.add(entry.getKey(), Reflections.cast(entry.getValue()));
if (!deployment.getServices().contains(ExecutorServices.class)) { addWeldService(ExecutorServices.class, executorServicesSupplier.get());
protected static void verifyServices(ServiceRegistry services, Set<Class<? extends Service>> requiredServices, Object target) { for (Class<? extends Service> serviceType : requiredServices) { if (!services.contains(serviceType)) { throw BootstrapLogger.LOG.unspecifiedRequiredService(serviceType.getName(), target); } } }
protected static void verifyServices(ServiceRegistry services, Set<Class<? extends Service>> requiredServices, Object target) { for (Class<? extends Service> serviceType : requiredServices) { if (!services.contains(serviceType)) { throw BootstrapLogger.LOG.unspecifiedRequiredService(serviceType.getName(), target); } } }
protected static void verifyServices(ServiceRegistry services, Set<Class<? extends Service>> requiredServices, Object target) { for (Class<? extends Service> serviceType : requiredServices) { if (!services.contains(serviceType)) { throw BootstrapLogger.LOG.unspecifiedRequiredService(serviceType.getName(), target); } } }
protected static void verifyServices(ServiceRegistry services, Set<Class<? extends Service>> requiredServices, Object target) { for (Class<? extends Service> serviceType : requiredServices) { if (!services.contains(serviceType)) { throw BootstrapLogger.LOG.unspecifiedRequiredService(serviceType.getName(), target); } } }
protected static void verifyServices(ServiceRegistry services, Set<Class<? extends Service>> requiredServices, Object target) { for (Class<? extends Service> serviceType : requiredServices) { if (!services.contains(serviceType)) { throw BootstrapLogger.LOG.unspecifiedRequiredService(serviceType.getName(), target); } } }
protected static void verifyServices(ServiceRegistry services, Set<Class<? extends Service>> requiredServices, Object target) { for (Class<? extends Service> serviceType : requiredServices) { if (!services.contains(serviceType)) { throw BootstrapLogger.LOG.unspecifiedRequiredService(serviceType.getName(), target); } } }
public <S extends Service> boolean contains(Class<S> type) { return delegate().contains(type); }
/** * * @param resolver * @param services * @param strict indicates whether event type should be performed or not * @return ObserverNotifier instance */ public static ObserverNotifier of(String contextId, TypeSafeObserverResolver resolver, ServiceRegistry services, boolean strict) { if (services.contains(TransactionServices.class)) { return new TransactionalObserverNotifier(contextId, resolver, services, strict); } else { return new ObserverNotifier(resolver, services, strict); } }
@Override public void postServiceRegistration(PostServiceRegistrationContext ctx) { if (ctx.getServices().contains(TransactionServices.class)) { ctx.getServices().add(ObserverNotifierFactory.class, TransactionalObserverNotifier.FACTORY); } }
@Override public void postServiceRegistration(PostServiceRegistrationContext ctx) { if (ctx.getServices().contains(TransactionServices.class)) { ctx.getServices().add(ObserverNotifierFactory.class, TransactionalObserverNotifier.FACTORY); } }
private <T extends Service> void copyService(BeanDeploymentArchive archive, Class<T> serviceClass) { // for certain services we can fall back to deployment-level settings or defaults ServiceRegistry registry = archive.getServices(); if (!registry.contains(serviceClass)) { T service = deployment.getServices().get(serviceClass); if (service != null) { registry.add(serviceClass, service); } } }
private <T extends Service> void copyService(BeanDeploymentArchive archive, Class<T> serviceClass) { // for certain services we can fall back to deployment-level settings or defaults ServiceRegistry registry = archive.getServices(); if (!registry.contains(serviceClass)) { T service = deployment.getServices().get(serviceClass); if (service != null) { registry.add(serviceClass, service); } } }
private <T extends Service> void copyService(BeanDeploymentArchive archive, Class<T> serviceClass) { // for certain services we can fall back to deployment-level settings or defaults ServiceRegistry registry = archive.getServices(); if (!registry.contains(serviceClass)) { T service = deployment.getServices().get(serviceClass); if (service != null) { registry.add(serviceClass, service); } } }
private <T extends Service> void copyService(BeanDeploymentArchive archive, Class<T> serviceClass) { // for certain services we can fall back to deployment-level settings or defaults ServiceRegistry registry = archive.getServices(); if (!registry.contains(serviceClass)) { T service = deployment.getServices().get(serviceClass); if (service != null) { registry.add(serviceClass, service); } } }
private <T extends Service> void copyService(BeanDeploymentArchive archive, Class<T> serviceClass) { // for certain services we can fall back to deployment-level settings or defaults ServiceRegistry registry = archive.getServices(); if (!registry.contains(serviceClass)) { T service = deployment.getServices().get(serviceClass); if (service != null) { registry.add(serviceClass, service); } } }
private <T extends Service> void copyService(BeanDeploymentArchive archive, Class<T> serviceClass) { // for certain services we can fall back to deployment-level settings or defaults ServiceRegistry registry = archive.getServices(); if (!registry.contains(serviceClass)) { T service = deployment.getServices().get(serviceClass); if (service != null) { registry.add(serviceClass, service); } } }
@Override public void preBeanRegistration(PreBeanRegistrationContext ctx) { if (ctx.getBeanManager().getServices().contains(TransactionServices.class)) { ctx.registerBean(new UserTransactionBean(ctx.getBeanManager())); } }
@Override public void preBeanRegistration(PreBeanRegistrationContext ctx) { if (ctx.getBeanManager().getServices().contains(TransactionServices.class)) { ctx.registerBean(new UserTransactionBean(ctx.getBeanManager())); } }