public void ProcessQuery(TwitterSearchRow query) { var searchResults = TwitterServiceInstance.Search(new SearchOptions { Count = 9, //TODO: este count tiene que ser 15 dividido la cantidad de queries Q = query.SearchTerm, SinceId = query.LastQueryId, Resulttype = TwitterSearchResultType.Popular, }); if (!searchResults.Statuses.Any()) { return; } foreach (var tweet in searchResults.Statuses) { TwitterServiceInstance.FavoriteTweet(new FavoriteTweetOptions { Id = tweet.Id }); query.FavouritedTW++; } query.LastQueryId = searchResults.Statuses.Max(x => x.Id); }
public void ProcessQuery(TwitterSearchRow query) { var searchResults = TwitterServiceInstance.Search(new SearchOptions { Count = 9, //TODO: este count tiene que ser 15 dividido la cantidad de queries Q = query.SearchTerm, SinceId = query.LastQueryId, Resulttype = TwitterSearchResultType.Popular, }); if (!searchResults.Statuses.Any()) return; foreach (var tweet in searchResults.Statuses) { TwitterServiceInstance.FavoriteTweet(new FavoriteTweetOptions { Id = tweet.Id }); query.FavouritedTW++; } query.LastQueryId = searchResults.Statuses.Max(x => x.Id); }