public CommandConsumerInitializer(
            CommandConsumerDefinition <TCommand, THandler> commandConsumerDefinition,
            IBus easyNetQBus,
            IEasyNetQMessageHandlerDispatcher dispatcher)
        {
            Guard.NotNull(dispatcher, nameof(dispatcher));
            Guard.NotNull(easyNetQBus, nameof(easyNetQBus));
            Guard.NotNull(commandConsumerDefinition, nameof(commandConsumerDefinition));

            this.commandConsumerDefinition = commandConsumerDefinition;
            this.easyNetQBus = easyNetQBus;
            this.dispatcher  = dispatcher;
        }
 public EventConsumerInitializer(
     EventConsumerDefinition <TEvent, THandler> eventConsumerDefinition,
     IBus easyNetQBus,
     IEasyNetQMessageHandlerDispatcher dispatcher,
     ConnectionConfiguration connectionConfiguration)
 {
     Guard.NotNull(connectionConfiguration, nameof(connectionConfiguration));
     Guard.NotNull(dispatcher, nameof(dispatcher));
     Guard.NotNull(easyNetQBus, nameof(easyNetQBus));
     Guard.NotNull(eventConsumerDefinition, nameof(eventConsumerDefinition));
     this.eventConsumerDefinition = eventConsumerDefinition;
     this.easyNetQBus             = easyNetQBus;
     this.dispatcher = dispatcher;
     this.connectionConfiguration = connectionConfiguration;
 }