X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FRevision%2FRevisionLookup.php;h=17cafc6a5d745c5254183173b70eeef507830509;hb=7baed424895d4fe38aa8a7215384724685eca88f;hp=db6c7c30b4f6261a067dd408ee2e1c0aac074d78;hpb=6ac8c496d16c1f88d1b8b4cf449085301ddefdce;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Revision/RevisionLookup.php b/includes/Revision/RevisionLookup.php index db6c7c30b4..17cafc6a5d 100644 --- a/includes/Revision/RevisionLookup.php +++ b/includes/Revision/RevisionLookup.php @@ -85,11 +85,12 @@ interface RevisionLookup extends IDBAccessObject { * MCR migration note: this replaces Revision::getPrevious * * @param RevisionRecord $rev - * @param Title|null $title if known (optional) + * @param int $flags (optional) $flags include: + * IDBAccessObject::READ_LATEST: Select the data from the master * * @return RevisionRecord|null */ - public function getPreviousRevision( RevisionRecord $rev, Title $title = null ); + public function getPreviousRevision( RevisionRecord $rev, $flags = 0 ); /** * Get next revision for this title @@ -97,11 +98,24 @@ interface RevisionLookup extends IDBAccessObject { * MCR migration note: this replaces Revision::getNext * * @param RevisionRecord $rev - * @param Title|null $title if known (optional) + * @param int $flags (optional) $flags include: + * IDBAccessObject::READ_LATEST: Select the data from the master * * @return RevisionRecord|null */ - public function getNextRevision( RevisionRecord $rev, Title $title = null ); + public function getNextRevision( RevisionRecord $rev, $flags = 0 ); + + /** + * Get rev_timestamp from rev_id, without loading the rest of the row. + * + * MCR migration note: this replaces Revision::getTimestampFromId + * + * @param int $id + * @param int $flags + * @return string|bool False if not found + * @since 1.34 (present earlier in RevisionStore) + */ + public function getTimestampFromId( $id, $flags = 0 ); /** * Load a revision based on a known page ID and current revision ID from the DB