コード例 #1
0
 /// <summary>
 /// 获取list
 /// </summary>
 public void searchList()
 {
     foreach (var listd in db.getLTLMaxid())
     {
         ulong newid;
         var   result = SelfieTweetFilter.Filter(TweetHelper.GetList(authapp, listd.UID, listd.LIST, ulong.Parse(listd.SINCEID), out newid));
         listd.SINCEID = newid.ToString();
         db.updateLTLMaxid(listd);
         if (result.Count > 0)
         {
             var todownload = SelfieTweetFilter.GetImageURL(result).ToArray();
             ImageDownloader.Download(todownload);
         }
     }
 }
コード例 #2
0
        /// <summary>
        /// 查找本人timeline
        /// </summary>
        public void searchTimeline()
        {
            ulong HTLMaxid = db.getHTLMaxid();
            ulong newid;

            DebugLogger.Instance.W("searchTimeline HTLMaxid:" + HTLMaxid);
            var result = SelfieTweetFilter.Filter(TweetHelper.GetHomeTL(authuser, HTLMaxid, out newid));

            DebugLogger.Instance.W("searchTimeline newid:" + newid);
            db.updateHTLMaxid(newid);

            if (result.Count > 0)
            {
                var todownload = SelfieTweetFilter.GetImageURL(result).ToArray();
                ImageDownloader.Download(todownload);
            }
        }
コード例 #3
0
        /// <summary>
        /// 根据定义的关键字查找
        /// </summary>
        public void SearchTweets()
        {
            foreach (var kv in db.getSearchKey())
            {
                ulong maxid;
                DebugLogger.Instance.W("SearchTweets:" + kv.Value + " >" + kv.Key);

                var bids   = TweetHelper.GetBlockedIDs(authuser);
                var result = SelfieTweetFilter.Filter(TweetHelper.SearchTweet(authapp, kv.Key, kv.Value, out maxid), bids);

                DebugLogger.Instance.W("SearchTweets newid  >" + maxid);
                db.updateSearchKey(kv.Key, maxid);

                if (result.Count > 0)
                {
                    var todownload = SelfieTweetFilter.GetImageURL(result).ToArray();
                    ImageDownloader.Download(todownload);
                }
            }
        }