using System.Collections.Generic; namespace Tapeti.Connection { public class TapetiSubscriber : ISubscriber { private readonly TapetiWorker worker; public TapetiSubscriber(TapetiWorker worker, IEnumerable registrations) { this.worker = worker; ApplyTopology(registrations); } private void ApplyTopology(IEnumerable registrations) { foreach (var registration in registrations) registration.ApplyTopology(worker.GetChannel()); } } }