Manual:RevisionLookup.php
MediaWiki file: RevisionLookup.php | |
---|---|
Location: | includes/Revision/ |
Source code: | master • 1.42.3 • 1.41.4 • 1.39.10 |
Classes: | MediaWiki\Revision\RevisionLookup |
Service class for looking up the RevisionRecord of a page. Extends IDBAccessObject.
Public methods
editGet the RevisionRecord:
- getRevisionById() - get RevisionRecord by revision ID number.
- getRevisionByTitle() - get RevisionRecord by PageIdentity. Calling with LinkTarget instead is deprecated since MW 1.36.
- getRevisionByPageId - get RevisionRecord by Page ID.
- getRevisionByTimestamp()
History-based methods:
- getPreviousRevision()
- getNextRevision()
- getKnownCurrentRevision() - load a revision based on a known page ID and current revision ID from the DB. Allows for caching
- getFirstRevision() - get the first revision of the page.
Look up associated properties:
- getTimestampFromId()
See also
edit- Manual:Revision
- Classes :
- Manual:RevisionRecord.php
- Manual:Revision.php used to contain methods that are adopted by RevisionLookup.