Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
1 | <?php |
2 | |
3 | namespace MediaWiki\Cache\Hook; |
4 | |
5 | use MediaWiki\Title\Title; |
6 | |
7 | /** |
8 | * This is a hook handler interface, see docs/Hooks.md. |
9 | * Use the hook name "HtmlCacheUpdaterAppendUrls" to register handlers implementing this interface. |
10 | * |
11 | * @stable to implement |
12 | * @ingroup Hooks |
13 | */ |
14 | interface HtmlCacheUpdaterAppendUrlsHook { |
15 | /** |
16 | * This hook is used to declare extra URLs to purge from HTTP caches. |
17 | * |
18 | * Use $mode to decide whether to gather all related URLs or only those affected by a |
19 | * re-render of the same content. For example, after a direct revision to the content the |
20 | * history page will need to be purged. However when re-rendering after a cascading change |
21 | * from a template, only URLs that render content need purging. The $mode will be either |
22 | * HTMLCacheUpdater::PURGE_URLS_LINKSUPDATE_ONLY or 0. |
23 | * |
24 | * @since 1.35 |
25 | * |
26 | * @param Title $title Title of the page being updated |
27 | * @param int $mode |
28 | * @param array &$append Append URLs relating to the title |
29 | * @return bool|void True or no return value to continue or false to abort |
30 | */ |
31 | public function onHtmlCacheUpdaterAppendUrls( $title, $mode, &$append ); |
32 | } |