Beispiel #1
0
 /// <summary>
 /// The on publisher sent.
 /// </summary>
 /// <param name="sender">
 /// The sender.
 /// </param>
 /// <param name="args">
 /// The eventArgs.
 /// </param>
 private void OnPublisherSent(object sender, PublisherSentEventArgs args)
 {
     if (this.PublisherSent != null)
     {
         this.PublisherSent(sender, args);
     }
 }
Beispiel #2
0
 /// <summary>
 /// The publisher send.
 /// </summary>
 /// <param name="publisher">
 /// The publisher.
 /// </param>
 /// <param name="message">
 /// The message.
 /// </param>
 /// <returns>
 /// The <see cref="IDisposable"/>.
 /// </returns>
 public IDisposable PublisherSend(IPublisher publisher, IMessage message)
 {
     return(GetActivityTracker(
                () =>
     {
         var args = new PublisherSendingEventArgs {
             Message = message
         };
         this.OnPublisherSending(publisher, args);
     },
                t =>
     {
         var args = new PublisherSentEventArgs {
             Elapsed = t, Message = message
         };
         this.OnPublisherSent(publisher, args);
     }));
 }
 /// <summary>
 /// The publisher send.
 /// </summary>
 /// <param name="publisher">
 /// The publisher.
 /// </param>
 /// <param name="message">
 /// The message.
 /// </param>
 /// <returns>
 /// The <see cref="IDisposable"/>.
 /// </returns>
 public IDisposable PublisherSend(IPublisher publisher, IMessage message)
 {
     return GetActivityTracker(
         () =>
             {
                 var args = new PublisherSendingEventArgs { Message = message };
                 this.OnPublisherSending(publisher, args);
             }, 
         t =>
             {
                 var args = new PublisherSentEventArgs { Elapsed = t, Message = message };
                 this.OnPublisherSent(publisher, args);
             });
 }
 /// <summary>
 /// The on publisher sent.
 /// </summary>
 /// <param name="sender">
 /// The sender.
 /// </param>
 /// <param name="args">
 /// The eventArgs.
 /// </param>
 private void OnPublisherSent(object sender, PublisherSentEventArgs args)
 {
     if (this.PublisherSent != null)
     {
         this.PublisherSent(sender, args);
     }
 }