public static List <Person> executePersonSearch(string keyword, AccountTwitter account) { List <Person> searchResults = new List <Person>(); SearchForUserOptions options = new TweetSharp.SearchForUserOptions(); options.Q = keyword; IEnumerable <TwitterUser> users = account.twitterService.SearchForUser(options); if (users != null) { foreach (TwitterUser user in users) { Person person = API.TweetSharpConverter.getPersonFromUser(user, account); searchResults.Add(person); } } return(searchResults); }
public virtual void SearchForUser(SearchForUserOptions options, Action<IEnumerable<TwitterUser>, TwitterResponse> action) { var q = options.Q; var page = options.Page; var count = options.Count; var include_entities = options.IncludeEntities; WithHammock(action, "users/search", FormatAsString, "?q=", q, "&page=", page, "&count=", count, "&include_entities=", include_entities); }
public virtual IAsyncResult BeginSearchForUser(SearchForUserOptions options) { var q = options.Q; var page = options.Page; var count = options.Count; var include_entities = options.IncludeEntities; return BeginWithHammock<IEnumerable<TwitterUser>>(WebMethod.Get, "users/search", FormatAsString, "?q=", q, "&page=", page, "&count=", count, "&include_entities=", include_entities); }
public virtual Task<TwitterResponse<IEnumerable<TwitterUser>>> SearchForUserAsync(SearchForUserOptions options) { var q = options.Q; var page = options.Page; var count = options.Count; var include_entities = options.IncludeEntities; return ExecuteRequest<IEnumerable<TwitterUser>>("users/search", FormatAsString, "?q=", q, "&page=", page, "&count=", count, "&include_entities=", include_entities); }
public virtual Task<TwitterAsyncResult<IEnumerable<TwitterUser>>> SearchForUserAsync(SearchForUserOptions options) { var q = options.Q; var page = options.Page; var count = options.Count; var include_entities = options.IncludeEntities; return WithHammockTask<IEnumerable<TwitterUser>>(_client, "users/search", FormatAsString, "?q=", q, "&page=", page, "&count=", count, "&include_entities=", include_entities); }