Static Public Member Functions | |
| static | checkPurge ($timekey, $key) |
| Check whether feed's cache should be cleared; for changes feeds If the feed should be purged; $timekey and $key will be removed from $messageMemc. | |
| static | checkFeedOutput ($type) |
| Check whether feeds can be used and that $type is a valid feed type. | |
| static | formatDiff ($row) |
| Format a diff for the newsfeed. | |
| static | formatDiffRow ($title, $oldid, $newid, $timestamp, $comment, $actiontext='') |
| Really format a diff for the newsfeed. | |
| static | applyDiffStyle ($text) |
| Hacky application of diff styles for the feeds. | |
Definition at line 8 of file FeedUtils.php.
| static FeedUtils::applyDiffStyle | ( | $ | text | ) | [static] |
Hacky application of diff styles for the feeds.
Might be 'cleaner' to use DOM or XSLT or something, but *gack* it's a pain in the ass.
| $text | String: diff's HTML output |
Definition at line 172 of file FeedUtils.php.
Referenced by formatDiffRow().
| static FeedUtils::checkFeedOutput | ( | $ | type | ) | [static] |
Check whether feeds can be used and that $type is a valid feed type.
| $type | String: feed type, as requested by the user |
Definition at line 33 of file FeedUtils.php.
References $wgFeed, $wgFeedClasses, $wgOut, and wfHttpError().
Referenced by ChangesFeed::execute(), and HistoryPage::feed().
| static FeedUtils::checkPurge | ( | $ | timekey, | |
| $ | key | |||
| ) | [static] |
Check whether feed's cache should be cleared; for changes feeds If the feed should be purged; $timekey and $key will be removed from $messageMemc.
| $timekey | String: cache key of the timestamp of the last item | |
| $key | String: cache key of feed's content |
Definition at line 18 of file FeedUtils.php.
References $messageMemc, $purge, $wgRequest, and $wgUser.
Referenced by ChangesFeed::execute().
| static FeedUtils::formatDiff | ( | $ | row | ) | [static] |
Format a diff for the newsfeed.
| $row | Object: row from the recentchanges table |
Definition at line 56 of file FeedUtils.php.
References $wgUser, LogPage::actionText(), LogPage::DELETED_ACTION, Revision::DELETED_COMMENT, LogPage::extractParams(), formatDiffRow(), Title::makeTitle(), wfMsgHtml(), and wfTimestamp().
Referenced by ChangesFeed::generateFeed().
| static FeedUtils::formatDiffRow | ( | $ | title, | |
| $ | oldid, | |||
| $ | newid, | |||
| $ | timestamp, | |||
| $ | comment, | |||
| $ | actiontext = '' | |||
| ) | [static] |
Really format a diff for the newsfeed.
| $title | Title object | |
| $oldid | Integer: old revision's id | |
| $newid | Integer: new revision's id | |
| $timestamp | Integer: new revision's timestamp | |
| $comment | String: new revision's comment | |
| $actiontext | String: text of the action; in case of log event |
Definition at line 88 of file FeedUtils.php.
References $title, $wgContLang, $wgFeedDiffCutoff, $wgUser, applyDiffStyle(), UtfNormal::cleanUp(), Revision::newFromId(), wfMsg(), wfMsgForContent(), wfProfileIn(), and wfProfileOut().
Referenced by HistoryPage::feedItem(), and formatDiff().
1.5.9