|
MediaWiki master
|
Helper class for mapping page value objects to a string key. More...
Static Public Member Functions | |
| static | getKeyForPage ( $page) |
| Returns a stable key for identifying the given page in a cache. | |
Helper class for mapping page value objects to a string key.
This logic should not reside in a class like PageStoreRecord or Title, because:
Furthermore, the logic for deriving cache keys also should not reside in a service class, because there must only ever be one implementation, it must not depend on configuration, and it may never change.
Definition at line 32 of file CacheKeyHelper.php.
|
static |
Returns a stable key for identifying the given page in a cache.
The return value takes into account the page's DB key, namespace and wiki ID or interwiki prefix. It is suitable for use with BagOStuff::makeKey and BagOStuff::makeGlobalKey.
| LinkTarget | PageReference | $page |
Definition at line 56 of file CacheKeyHelper.php.
Referenced by MediaWiki\Deferred\HtmlFileCacheUpdate\newFromPages().