Ejemplo n.º 1
0
 public EasyNetQMessageHandlerDispatcher(IInputMessageChannel dispatcher, IMessageContextFactory factory)
 {
     Guard.NotNull(factory, nameof(factory));
     Guard.NotNull(dispatcher, nameof(dispatcher));
     this.dispatcher = dispatcher;
     this.factory    = factory;
 }
 public InputMessageChannelController(IInputMessageChannel channel, IMessageContextFactory messageContextFactory)
 {
     Guard.NotNull(messageContextFactory, nameof(messageContextFactory));
     Guard.NotNull(channel, nameof(channel));
     this.channel = channel;
     this.messageContextFactory = messageContextFactory;
 }
Ejemplo n.º 3
0
 public RequestConsumerInitializer(IBus easyNetQBus, IInputMessageChannel dispatcher, IMessageContextFactory messageContextFactory)
 {
     Guard.NotNull(messageContextFactory, nameof(messageContextFactory));
     Guard.NotNull(dispatcher, nameof(dispatcher));
     Guard.NotNull(easyNetQBus, nameof(easyNetQBus));
     Guard.NotNull(easyNetQBus, nameof(easyNetQBus));
     this.easyNetQBus           = easyNetQBus;
     this.dispatcher            = dispatcher;
     this.messageContextFactory = messageContextFactory;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// メッセージ チャネルにメッセージを送信します。
 /// </summary>
 /// <typeparam name="TMessage">メッセージを表す非 <c>null</c> 型。</typeparam>
 /// <param name="messageChannel">対象のメッセージ チャネル。</param>
 /// <param name="message">チャネルへ送信するメッセージ。</param>
 /// <exception cref="MessagingException">メッセージ チャネルのエラーにより、メッセージの送信に失敗した。</exception>
 /// <exception cref="OperationCanceledException">キャンセル要求に従い、操作が中止された。</exception>
 public static Task PostAsync <TMessage>(this IInputMessageChannel <TMessage> messageChannel, TMessage message) => messageChannel.PostAsync(message, cancellationToken: default);
 public InMemoryOutputMessageChannel(IInputMessageChannel inputMessageChannel)
 {
     Guard.NotNull(inputMessageChannel, nameof(inputMessageChannel));
     this.inputMessageChannel = inputMessageChannel;
 }