Example #1
0
 public StartDeliveryHandler(IDeliveriesRepository repository, IMessageBroker messageBroker,
     IEventMapper eventMapper)
 {
     _repository = repository;
     _messageBroker = messageBroker;
     _eventMapper = eventMapper;
 }
Example #2
0
 public AddDeliveryRegistrationHandler(IDeliveriesRepository repository, IMessageBroker messageBroker,
                                       IEventMapper eventMapper)
 {
     _repository    = repository;
     _messageBroker = messageBroker;
     _eventMapper   = eventMapper;
 }
 /// <summary>
 /// Creates a new instance of the NotificationsController class.
 /// </summary>
 /// <param name="notificationsRepo"></param>
 /// <param name="deliverersRepo"></param>
 /// <param name="locationsRepo"></param>
 /// <param name="logger"></param>
 public NotificationsController(INotificationsRepository notificationsRepo, IDeliveriesRepository deliveriesRepo, IDeliverersRepository deliverersRepo, ILocationsRepository locationsRepo, ILogger logger)
 {
     _logger = logger;
     _notificationsService  = new NotificationsService(deliverersRepo, deliveriesRepo, notificationsRepo, locationsRepo, _logger);
     _deliverersService     = new DeliverersService(deliverersRepo, _logger);
     _authorizationsService = new AuthenticationsService(_logger);
 }
Example #4
0
 public CompleteDeliveryHandler(IDeliveriesRepository deliveriesRepository, IMessageBroker messageBroker,
                                ILogger <CompleteDeliveryHandler> logger)
 {
     _deliveriesRepository = deliveriesRepository;
     _messageBroker        = messageBroker;
     _logger = logger;
 }
Example #5
0
 public CompleteDeliveryHandler(IDeliveriesRepository deliveriesRepository,
                                IDomainEventPublisher domainEventPublisher, IDispatcher dispatcher, ILogger <CompleteDeliveryHandler> logger)
 {
     _deliveriesRepository = deliveriesRepository;
     _domainEventPublisher = domainEventPublisher;
     _dispatcher           = dispatcher;
     _logger = logger;
 }
Example #6
0
 public DeliveriesController(IDeliveriesRepository deliveriesRepository,
                             IRepository <Category> categoriesRepo,
                             IRepository <Product> productsRepo)
 {
     _deliveriesRepository = deliveriesRepository;
     _categoriesRepo       = categoriesRepo;
     _productsRepo         = productsRepo;
 }
Example #7
0
 /// <summary>
 /// Public constructor, unavailable outside this class
 /// </summary>
 /// <param name="deliverersRepo"></param>
 /// <param name="notificationsRepo"></param>
 /// <param name="locationsRepo"></param>
 /// <param name="deliveriesRepo"></param>
 /// <param name="logger"></param>
 public NotificationsService(IDeliverersRepository deliverersRepo, IDeliveriesRepository deliveriesRepo, INotificationsRepository notificationsRepo, ILocationsRepository locationsRepo, ILogger logger)
 {
     this._notificationsRepo = notificationsRepo;
     this._logger            = logger;
     this.rnd = new Random();
     this._locationsService  = new LocationsService(locationsRepo, _logger);
     this._deliverersService = new DeliverersService(deliverersRepo, _logger);
     this._deliveriesService = new DeliveriesService(deliveriesRepo, locationsRepo, _logger);
 }
Example #8
0
 public StartDeliveryHandler(IDeliveriesRepository deliveriesRepository, IParcelsRepository parcelsRepository,
                             IRoutingServiceClient routingServiceClient, IMessageBroker messageBroker,
                             ILogger <StartDeliveryHandler> logger)
 {
     _deliveriesRepository = deliveriesRepository;
     _parcelsRepository    = parcelsRepository;
     _routingServiceClient = routingServiceClient;
     _messageBroker        = messageBroker;
     _logger = logger;
 }
Example #9
0
 public StartDeliveryHandler(IDeliveriesRepository deliveriesRepository, IParcelsRepository parcelsRepository,
                             IRoutingServiceClient routingServiceClient, IDomainEventPublisher domainEventPublisher,
                             IDispatcher dispatcher, ILogger <StartDeliveryHandler> logger)
 {
     _deliveriesRepository = deliveriesRepository;
     _parcelsRepository    = parcelsRepository;
     _routingServiceClient = routingServiceClient;
     _domainEventPublisher = domainEventPublisher;
     _dispatcher           = dispatcher;
     _logger = logger;
 }
 public DeliveriesController(IDeliveriesRepository deliveriesRepository, IMapper mapper)
 {
     _deliveriesRepository = deliveriesRepository ?? throw new ArgumentNullException(nameof(deliveriesRepository));
     _mapper = mapper;
 }
 public FailDeliveryHandler(IDeliveriesRepository repository, IMessageBroker messageBroker, IEventMapper eventMapper)
     : base(messageBroker, eventMapper)
 {
     _repository = repository;
 }
Example #12
0
 public DeliveriesController(IDeliveriesRepository deliveriesRepository)
 {
     _deliveriesRepository = deliveriesRepository ?? throw new ArgumentNullException(nameof(deliveriesRepository));
 }
Example #13
0
 /// <summary>
 /// Public constructor, unavailable outside this class
 /// </summary>
 /// <param name="deliveriesRepo"></param>
 /// <param name="locationsRepo"></param>
 /// <param name="logger"></param>
 public DeliveriesService(IDeliveriesRepository deliveriesRepo, ILocationsRepository locationsRepo, ILogger logger)
 {
     _logger = logger;
     _deliveriesRepository = deliveriesRepo;
     _locationsService     = new LocationsService(locationsRepo, _logger);
 }