Ejemplo n.º 1
0
 public async Task RunCommandAsync(ITelegramMessage message)
 {
     try
     {
         var result = await _comandos[message.Comando].RunAsync(message.Update);
         NotifyChat(message.ChatId, result);
     }
     catch (ComandoInexistenteException e)
     {
         Trace.WriteLine(e.Message);
         NotifyChat(message.ChatId, e.Message);
     }
 }
Ejemplo n.º 2
0
 public void RunCommand(ITelegramMessage message)
 {
     try
     {
         var result = _comandos[message.Comando].Run(message.Update);
         NotifyChat(message.ChatId, result);
     }
     catch (ComandoInexistenteException e)
     {
         Trace.WriteLine(e.Message);
         NotifyChat(message.ChatId, e.Message);
     }
 }
Ejemplo n.º 3
0
 public async Task RunCommandAsync(ITelegramMessage message)
 {
     try
     {
         var result = await _comandos[message.Comando].RunAsync(message.Update);
         NotifyChat(message.ChatId, result);
     }
     catch (ComandoInexistenteException e)
     {
         Trace.WriteLine(e.Message);
         NotifyChat(message.ChatId, e.Message);
     }
 }
Ejemplo n.º 4
0
 public void RunCommand(ITelegramMessage message)
 {
     try
     {
         var result = _comandos[message.Comando].Run(message.Update);
         NotifyChat(message.ChatId, result);
     }
     catch (ComandoInexistenteException e)
     {
         Trace.WriteLine(e.Message);
         NotifyChat(message.ChatId, e.Message);
     }
 }
Ejemplo n.º 5
0
 public async Task NotifyTelegram(ITelegramMessage message)
 {
     await telegramHub.Clients.All.SendAsync("OnTelegram", message);
 }
Ejemplo n.º 6
0
 private Task NotifyTelegram(ITelegramMessage message)
 {
     return(_monitor.NotifyTelegram(message));
 }
Ejemplo n.º 7
0
 public Task NotifyTelegram(ITelegramMessage message)
 {
     return(Task.CompletedTask);
 }