Пример #1
0
 public Task Publish(object message, PublishOptions options = null)
 {
     return(this.unit.Publish(message, options));
 }
Пример #2
0
 public Task Publish(object message, PublishOptions options = null)
 {
     return(this.Publish(message, options, incoming: null));
 }
Пример #3
0
 public Task Publish(object message, PublishOptions options = null)
 {
     return this.Publish(message, options, incoming: null);
 }
Пример #4
0
 public Task Publish(object message, PublishOptions options = null)
 {
     return this.unit.Publish(message, options);
 }
Пример #5
0
        private Task Publish(object message, PublishOptions options, TransportMessage incoming)
        {
            if (message == null)
            {
                throw new ArgumentNullException("message", "You cannot publish null");
            }

            var publishOptions = options ?? new PublishOptions();
            LogicalMessage msg = this.factory.Create(message, publishOptions.Headers);
            publishOptions.EventType = msg.MessageType;

            return this.SendMessage(msg, publishOptions, incoming);
        }