EndSend() приватный Метод

private EndSend ( IAsyncResult asyncResult ) : void
asyncResult IAsyncResult
Результат void
Пример #1
0
 void SendMessageCallback(IAsyncResult result)
 {
     GlobalLog.Enter("SmtpClient#" + ValidationHelper.HashString(this) + "::SendMessageCallback");
     try {
         message.EndSend(result);
         // If some recipients failed but not others, throw AFTER sending the message.
         Complete(failedRecipientException, result);
     }
     catch (Exception e) {
         Complete(e, result);
     }
     GlobalLog.Leave("SmtpClient#" + ValidationHelper.HashString(this) + "::SendMessageCallback");
 }
Пример #2
0
 private void SendMessageCallback(IAsyncResult result)
 {
     if (GlobalLog.IsEnabled)
     {
         GlobalLog.Enter("SmtpClient#" + LoggingHash.HashString(this) + "::SendMessageCallback");
     }
     try
     {
         _message.EndSend(result);
         // If some recipients failed but not others, throw AFTER sending the message.
         Complete(_failedRecipientException, result);
     }
     catch (Exception e)
     {
         Complete(e, result);
     }
     if (GlobalLog.IsEnabled)
     {
         GlobalLog.Leave("SmtpClient#" + LoggingHash.HashString(this) + "::SendMessageCallback");
     }
 }
Пример #3
0
 private void SendMessageCallback(IAsyncResult result)
 {
     if (NetEventSource.IsEnabled)
     {
         NetEventSource.Enter(this);
     }
     try
     {
         _message.EndSend(result);
         // If some recipients failed but not others, throw AFTER sending the message.
         Complete(_failedRecipientException, result);
     }
     catch (Exception e)
     {
         Complete(e, result);
     }
     finally
     {
         if (NetEventSource.IsEnabled)
         {
             NetEventSource.Exit(this);
         }
     }
 }