Beispiel #1
0
        public void Save(Tweet item)
        {
            IList<Tweet> existingItems = GetTweets(item.CreationDate.Date);

            if(existingItems.Any(x => x.Id == item.Id))
                return;

            SaveTweets(DateTime.UtcNow.Date, existingItems);
        }
Beispiel #2
0
        Tweet ConvertTweet(dynamic tweet)
        {
            Tweet t = new Tweet();
            t.Id = tweet.id;
            t.Text = tweet.text;
            t.CreationDate = DateTime.ParseExact((string)tweet.created_at, "ddd MMM dd HH:mm:ss zzz yyyy", CultureInfo.InvariantCulture);

            return t;
        }
Beispiel #3
0
 public void Delete(Tweet item)
 {
     throw new NotImplementedException();
 }