public MessageListViewModel(
            MessageRepository messageRepository,
            [NotNull] MessageWatcher messageWatcher,
            MimeMessageLoader mimeMessageLoader,
            IPublishEvent publishEvent,
            ILogger logger)
        {
            if (messageRepository == null)
                throw new ArgumentNullException("messageRepository");
            if (messageWatcher == null)
                throw new ArgumentNullException("messageWatcher");
            if (mimeMessageLoader == null)
                throw new ArgumentNullException("mimeMessageLoader");
            if (publishEvent == null)
                throw new ArgumentNullException("publishEvent");

            _messageRepository = messageRepository;
            _messageWatcher = messageWatcher;
            _mimeMessageLoader = mimeMessageLoader;
            _publishEvent = publishEvent;
            _logger = logger;

            SetupMessages();
            RefreshMessageList();
        }
 public ReceivedDataMessageHandler(MessageRepository messageRepository,
     IPublishEvent publishEvent,
     ILogger logger)
 {
     _messageRepository = messageRepository;
     _publishEvent = publishEvent;
     _logger = logger;
 }
Esempio n. 3
0
 public MimeMessageLoader(MessageRepository messageRepository, ILogger logger)
 {
     _messageRepository = messageRepository;
     _logger = logger.ForContext<MimeMessageLoader>();
 }
Esempio n. 4
0
 public MimeMessageLoader(MessageRepository messageRepository, ILogger logger)
 {
     _messageRepository = messageRepository;
     _logger            = logger.ForContext <MimeMessageLoader>();
 }