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\Hook; |
4 | |
5 | /** |
6 | * This is a hook handler interface, see docs/Hooks.md. |
7 | * Use the hook name "GetLangPreferredVariant" to register handlers implementing this interface. |
8 | * |
9 | * @stable to implement |
10 | * @ingroup Hooks |
11 | */ |
12 | interface GetLangPreferredVariantHook { |
13 | /** |
14 | * This hook is called in LanguageConverter#getPreferredVariant() to |
15 | * allow fetching the language variant code from cookies or other such |
16 | * alternative storage. |
17 | * |
18 | * @since 1.35 |
19 | * |
20 | * @param string|null &$req Language variant from the URL or null if no variant |
21 | * was specified in the URL; the value of this variable comes from |
22 | * LanguageConverter#getURLVariant() |
23 | * @return bool|void True or no return value to continue or false to abort |
24 | */ |
25 | public function onGetLangPreferredVariant( &$req ); |
26 | } |