| 1 | <?php |
| 2 | |
| 3 | namespace MediaWiki\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 "TitleIsAlwaysKnown" to register handlers implementing this interface. |
| 10 | * |
| 11 | * @stable to implement |
| 12 | * @ingroup Hooks |
| 13 | */ |
| 14 | interface TitleIsAlwaysKnownHook { |
| 15 | /** |
| 16 | * This hook is called when determining if a page exists. Use this hook to |
| 17 | * override default behavior for determining if a page exists. If $isKnown is |
| 18 | * kept as null, regular checks happen. If it's a boolean, this value is returned |
| 19 | * by the isKnown method. |
| 20 | * |
| 21 | * @since 1.35 |
| 22 | * |
| 23 | * @param Title $title Title object that is being checked |
| 24 | * @param bool|null &$isKnown Whether MediaWiki currently thinks this page is known |
| 25 | * @return bool|void True or no return value to continue or false to abort |
| 26 | */ |
| 27 | public function onTitleIsAlwaysKnown( $title, &$isKnown ); |
| 28 | } |