Mercurial > hg > Feedworm
comparison backend/arangodb/FeedUpdater.py @ 259:304917762618 default tip
implementation of feed updates
author | Dirk Olmes <dirk@xanthippe.ping.de> |
---|---|
date | Tue, 12 Mar 2019 02:41:22 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
258:4ca1fac32dde | 259:304917762618 |
---|---|
1 # -*- coding: utf-8 -*- | |
2 from backend.AbstractFeedUpdater import AbstractFeedUpdater | |
3 from FeedEntry import FeedEntry | |
4 | |
5 class FeedUpdater(AbstractFeedUpdater): | |
6 def __init__(self, database, preferences): | |
7 super(FeedUpdater, self).__init__(preferences) | |
8 self.database = database | |
9 | |
10 def _incrementFeedUpdateDate(self): | |
11 self.feed.increment_next_update_date() | |
12 | |
13 def _processEntry(self, entry): | |
14 feed_entry = FeedEntry.find_by_link(entry.link, self.database) | |
15 if feed_entry is None: | |
16 self._createFeedEntry(entry) |