MediaWiki 1.42.1
|
Data record representing a page that is (or used to be, or could be) an editable page on a wiki. More...
Inherits MediaWiki\Page\ProperPageIdentity.
Inherited by MediaWiki\Page\ExistingPageRecord, and WikiPage.
Public Member Functions | |
getLanguage () | |
The page's language, if explicitly recorded. | |
getLatest ( $wikiId=self::LOCAL) | |
The ID of the page's latest revision. | |
getTouched () | |
Timestamp at which the page was last flagged for rerendering. | |
isNew () | |
False if the page has had more than one edit. | |
isRedirect () | |
True if the page is a redirect. | |
Public Member Functions inherited from MediaWiki\Page\ProperPageIdentity | |
canExist () | |
Always true. | |
getDBkey () | |
Get the page title in DB key form. | |
getId ( $wikiId=self::LOCAL) | |
Returns the page ID. | |
getWikiId () | |
Get the ID of the wiki this page belongs to. | |
Public Member Functions inherited from MediaWiki\Page\PageIdentity | |
exists () | |
Checks if the page currently exists. | |
Public Member Functions inherited from MediaWiki\Page\PageReference | |
__toString () | |
Returns an informative human readable unique representation of the page identity, for use as a cache key and for logging and debugging. | |
getNamespace () | |
Returns the page's namespace number. | |
isSamePageAs (PageReference $other) | |
Checks whether the given PageReference refers to the same page as this PageReference. | |
Public Member Functions inherited from MediaWiki\DAO\WikiAwareEntity | |
assertWiki ( $wikiId) | |
Throws if $wikiId is different from the return value of getWikiId(). | |
Data record representing a page that is (or used to be, or could be) an editable page on a wiki.
For compatibility with the WikiPage class, PageIdentity instances may represent non-existing pages. In the future, the contract of this interface is intended to be changed to disallow this. PageIdentity instances may also be mutable, and return different values from methods such as getLatest() or isRedirect() at different times. In the future, the contract of this interface is intended to be changed to disallow this.
Only WikiPage should implement PageRecord directly, other implementations should use ExistingPageRecord instead. Once WikiPage is removed or guaranteed to be immutable and existing, ExistingPageRecord will become an alias of PageRecord.
Definition at line 26 of file PageRecord.php.
MediaWiki\Page\PageRecord::getLanguage | ( | ) |
The page's language, if explicitly recorded.
The effective page language needs to be determined programmatically.
Implemented in MediaWiki\Page\PageStoreRecord, and WikiPage.
MediaWiki\Page\PageRecord::getLatest | ( | $wikiId = self::LOCAL | ) |
The ID of the page's latest revision.
string | false | $wikiId | Must be provided when accessing the ID of the latest revision of a non-local PageRecord, to prevent data corruption when using a PageRecord belonging to one wiki in the context of another. Should be omitted if expecting the local wiki. |
Implemented in MediaWiki\Page\PageStoreRecord, and WikiPage.
Referenced by ParserCache\save().
MediaWiki\Page\PageRecord::getTouched | ( | ) |
Timestamp at which the page was last flagged for rerendering.
Implemented in MediaWiki\Page\PageStoreRecord, and WikiPage.
MediaWiki\Page\PageRecord::isNew | ( | ) |
False if the page has had more than one edit.
Implemented in MediaWiki\Page\PageStoreRecord, and WikiPage.
MediaWiki\Page\PageRecord::isRedirect | ( | ) |
True if the page is a redirect.
Implemented in MediaWiki\Page\PageStoreRecord, WikiFilePage, and WikiPage.
Referenced by ParserCache\get().