Пример #1
0
 public Task<Message> StoreMessageAsync(Message message)
 {
     return _factory.ExecuteAsync<IMessageRepository, long>(
         messageRepository => messageRepository.InsertAsync(message.ToEntity())
     ).ContinueWith(task =>
     {
         message.Id = task.Result;
         return message;
     }, TaskContinuationOptions.OnlyOnRanToCompletion);
 }
 public TweetArrivedMessage(Message message)
 {
     Message = message;
 }
 public TweetSavedMessage(Message message)
 {
     Message = message;
 }