コード例 #1
0
 /// <summary>
 /// Provides a simple, relevance-based search interface to public user accounts on Twitter. Try querying by
 /// topical interest, full name, company name, location, or other criteria. Exact match searches are not
 /// supported.
 ///
 /// Only the first 1,000 matching results are available.
 /// </summary>
 /// <param name="options">The options for the call to the API.</param>
 public SocialHttpResponse Search(TwitterUsersSearchOptions options)
 {
     if (options == null)
     {
         throw new ArgumentNullException("options");
     }
     return(Client.DoHttpGetRequest("https://api.twitter.com/1.1/users/search.json", options));
 }
コード例 #2
0
        public string Search(string query, TwitterUsersSearchOptions options)
        {
            // Declare the query string
            SocialQueryString qs = new SocialQueryString();

            qs.Set("q", query);
            if (options != null)
            {
                qs.Set("page", options.Page, options.Page > 1);
                qs.Set("count", options.Count, options.Count != 20);
                qs.Set("include_entities", options.IncludeEntities, options.IncludeEntities != true);
            }

            // Make the call to the API
            return(Client.DoHttpRequestAsString("GET", "https://api.twitter.com/1.1/users/search.json", qs.NameValueCollection));
        }
コード例 #3
0
 /// <summary>
 /// Provides a simple, relevance-based search interface to public user
 /// accounts on Twitter. Try querying by topical interest, full name,
 /// company name, location, or other criteria. Exact match searches are
 /// not supported.
 /// </summary>
 /// <param name="query">The search query to run against people search.</param>
 /// <param name="options">The search options.</param>
 public TwitterUsersSearchResponse Search(string query, TwitterUsersSearchOptions options)
 {
     return(TwitterUsersSearchResponse.ParseJson(Raw.Search(query, options)));
 }