Debian Codegraph @

extensions/CodeEditor/includes/Hooks/CodeEditorGetPageLanguageHook.php

raw symbols SCIP
1 <?php
2
3 namespace MediaWiki\Extension\CodeEditor\Hooks;
4
5 use MediaWiki\Title\Title;
6
7 /**
8 * This is a hook handler interface, see docs/Hooks.md in core.
9 * Use the hook name "CodeEditorGetPageLanguage" to register handlers implementing this interface.
10 *
11 * @stable to implement
12 * @ingroup Hooks
13 */
14 interface CodeEditorGetPageLanguageHook {
15 /**
16 * Allows to set a code language for extensions content models
17 *
18 * @param Title $title The title the language is for
19 * @param string|null &$lang The language to use
20 * @param string $model The content model of the title
21 * @param string $format The content format of the title
22 * @return bool|void True or no return value to continue or false to abort
23 */
24 public function onCodeEditorGetPageLanguage( Title $title, ?string &$lang, string $model, string $format );
25 }