コード例 #1
0
 public Task<int> SendUserAMessage(User user, string message)
 {
     //simulate sending a message for this example
     return Task<int>.Factory.StartNew(() =>
     {
         Thread.Sleep(1000);
         return 1;
     });
     //return emailService.SendEmail(user.Email, message).ContinueWith(_ => 0);
 }
コード例 #2
0
 public ViewResult IndexCompleted(User user)
 {
     return View(user);
 }
コード例 #3
0
 public Task<int> SendUserAMessage(User user, string message)
 {
     return emailService.SendEmail(user.Email, message).ContinueWith(_ => 0);
 }