| [ Index ] |
PHP Cross Reference of MediaWiki-1.24.0 |
[Source view] [Print] [Project Stats]
Page existence cache. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
| File Size: | 285 lines (7 kb) |
| Included or required: | 0 times |
| Referenced: | 1 time |
| Includes or requires: | 0 files |
LinkCache:: (17 methods):
singleton()
destroySingleton()
setSingleton()
forUpdate()
getGoodLinkID()
getGoodLinkFieldObj()
isBadLink()
addGoodLinkObj()
addGoodLinkObjFromRow()
addBadLinkObj()
clearBadLink()
clearLink()
getGoodLinks()
getBadLinks()
addLink()
addLinkObj()
clear()
| singleton() X-Ref |
| Get an instance of this class. return: LinkCache |
| destroySingleton() X-Ref |
| Destroy the singleton instance, a new one will be created next time singleton() is called. |
| setSingleton( LinkCache $instance ) X-Ref |
| Set the singleton instance to a given object. Since we do not have an interface for LinkCache, you have to be sure the given object implements all the LinkCache public methods. param: LinkCache $instance |
| forUpdate( $update = null ) X-Ref |
| General accessor to get/set whether SELECT FOR UPDATE should be used param: bool $update return: bool |
| getGoodLinkID( $title ) X-Ref |
param: string $title return: int |
| getGoodLinkFieldObj( $title, $field ) X-Ref |
| Get a field of a title object from cache. If this link is not good, it will return NULL. param: Title $title param: string $field ('length','redirect','revision','model') return: string|null |
| isBadLink( $title ) X-Ref |
param: string $title return: bool |
| addGoodLinkObj( $id, $title, $len = -1, $redir = null,$revision = 0, $model = null) X-Ref |
| Add a link for the title to the link cache param: int $id Page's ID param: Title $title param: int $len Text's length param: int $redir Whether the page is a redirect param: int $revision Latest revision's ID param: string|null $model Latest revision's content model ID |
| addGoodLinkObjFromRow( $title, $row ) X-Ref |
| Same as above with better interface. param: Title $title param: stdClass $row Object which has the fields page_id, page_is_redirect, |
| addBadLinkObj( $title ) X-Ref |
param: Title $title |
| clearBadLink( $title ) X-Ref |
| No description |
| clearLink( $title ) X-Ref |
param: Title $title |
| getGoodLinks() X-Ref |
| No description |
| getBadLinks() X-Ref |
| No description |
| addLink( $title ) X-Ref |
| Add a title to the link cache, return the page_id or zero if non-existent param: string $title Title to add return: int |
| addLinkObj( $nt ) X-Ref |
| Add a title to the link cache, return the page_id or zero if non-existent param: Title $nt Title object to add return: int |
| clear() X-Ref |
| Clears cache |
| Generated: Fri Nov 28 14:03:12 2014 | Cross-referenced by PHPXref 0.7.1 |