@Test public void testIntroductionToTransports() { BindingDescriptorRegistrationListener mockTransport = mock(BindingDescriptorRegistrationListener.class); List<BindingDescriptorRegistrationListener> transports = new ArrayList<BindingDescriptorRegistrationListener>(); transports.add(mockTransport); cut.introduceServiceToTransports(transports.iterator()); verify(mockTransport).notify(any(BindingDescriptor.class)); }
public void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports) { while (transports.hasNext()) { BindingDescriptorRegistrationListener t = transports.next(); boolean eventTransport = t instanceof EventTransport; boolean includedEventTransport = false; if (eventTransport) { if (eventTransports != null && eventTransports.contains(t)) { includedEventTransport = true; } } if (!eventTransport || includedEventTransport) { for (BindingDescriptor bindingDescriptor : getBindingDescriptors()) { t.notify(bindingDescriptor); } } } }
ServiceRegistration extends AbstractServiceRegistration { public void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports) { while (transports.hasNext()) { BindingDescriptorRegistrationListener t = transports.next(); boolean eventTransport = t instanceof EventTransport; boolean includedEventTransport = false; if (eventTransport) { if (eventTransports != null && eventTransports.contains(t)) { includedEventTransport = true; } } if (!eventTransport || includedEventTransport) { for (BindingDescriptor bindingDescriptor : getBindingDescriptors()) { t.notify(bindingDescriptor); } } } } }
ServiceRegistration extends AbstractServiceRegistration { public void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports) { while (transports.hasNext()) { BindingDescriptorRegistrationListener t = transports.next(); boolean eventTransport = t instanceof EventTransport; boolean includedEventTransport = false; if (eventTransport) { if (eventTransports != null && eventTransports.contains(t)) { includedEventTransport = true; } } if (!eventTransport || includedEventTransport) { for (BindingDescriptor bindingDescriptor : getBindingDescriptors()) { t.notify(bindingDescriptor); } } } }  }
ServiceRegistration extends AbstractServiceRegistration { public void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports) { while (transports.hasNext()) { BindingDescriptorRegistrationListener t = transports.next(); boolean eventTransport = t instanceof EventTransport; boolean includedEventTransport = false; if (eventTransport) { if (eventTransports != null && eventTransports.contains(t)) { includedEventTransport = true; } } if (!eventTransport || includedEventTransport) { for (BindingDescriptor bindingDescriptor : getBindingDescriptors()) { t.notify(bindingDescriptor); } } } }  @Override void introduceServiceToEV(ExecutionVenue ev, ServiceRegistrar serviceRegistrar, CompoundExecutableResolver compoundExecutableResolver); void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports); void setEventTransports(Set<EventTransport> eventTransportSet); }
ServiceRegistration extends AbstractServiceRegistration { public void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports) { while (transports.hasNext()) { BindingDescriptorRegistrationListener t = transports.next(); boolean eventTransport = t instanceof EventTransport; boolean includedEventTransport = false; if (eventTransport) { if (eventTransports != null && eventTransports.contains(t)) { includedEventTransport = true; } } if (!eventTransport || includedEventTransport) { for (BindingDescriptor bindingDescriptor : getBindingDescriptors()) { t.notify(bindingDescriptor); } } } }  @Override void introduceServiceToEV(ExecutionVenue ev, ServiceRegistrar serviceRegistrar, CompoundExecutableResolver compoundExecutableResolver); void introduceServiceToTransports(Iterator<? extends BindingDescriptorRegistrationListener> transports); void setEventTransports(Set<EventTransport> eventTransportSet);  }