Esempio n. 1
0
 public async Task ExcuteAsync()
 {
     if (RequestMessage.ToLower().Contains("#>Urls".ToLower()))
     {
         UrlManager _manager = new UrlManager();
         var        _urls    = _manager.GetAllUrls().Select(t => t.Address);
         if (_urls != null && _urls.Count() > 0)
         {
             foreach (string url in _urls)
             {
                 await TalkAsync(url);
             }
         }
     }
     else if (RequestMessage.ToLower().Contains("#>Users".ToLower()))
     {
         UserManager _manager = new UserManager();
         var         _urls    = _manager.GetAll().Select(t => t.UserName);
         if (_urls != null && _urls.Count() > 0)
         {
             foreach (string url in _urls)
             {
                 await TalkAsync(url);
             }
         }
     }
     else
     {
         await ProcessResult();
     }
 }