Handles the NOEXTERNALLANGLINKS parser function.
More...
Handles the NOEXTERNALLANGLINKS parser function.
- Copyright
- GPL-2.0-or-later
- Author
- Nikola Smolenski smole.nosp@m.nsk@.nosp@m.eunet.nosp@m..rs
-
Katie Filbert < aude..nosp@m.wiki.nosp@m.@gmai.nosp@m.l.co.nosp@m.m >
-
Daniel Kinzler
◆ __construct()
Wikibase\Client\Hooks\NoLangLinkHandler::__construct |
( |
NamespaceChecker |
$namespaceChecker | ) |
|
◆ appendNoExternalLangLinks()
static Wikibase\Client\Hooks\NoLangLinkHandler::appendNoExternalLangLinks |
( |
ParserOutput |
$parserOutput, |
|
|
array |
$noexternallanglinks |
|
) |
| |
|
static |
Append new languages to the noexternallanglinks data in the ParserOutput, which is set by the {{#noexternallanglinks}} parser function.
- Parameters
-
ParserOutput | $parserOutput | |
string[] | $noexternallanglinks | a list of languages to suppress |
◆ doHandle()
Wikibase\Client\Hooks\NoLangLinkHandler::doHandle |
( |
Parser |
$parser, |
|
|
array |
$langs |
|
) |
| |
Parser function.
- Parameters
-
Parser | $parser | |
string[] | $langs | |
- Returns
- string
◆ factory()
static Wikibase\Client\Hooks\NoLangLinkHandler::factory |
( |
| ) |
|
|
staticprivate |
◆ getNoExternalLangLinks()
static Wikibase\Client\Hooks\NoLangLinkHandler::getNoExternalLangLinks |
( |
ParserOutput |
$parserOutput | ) |
|
|
static |
Get the noexternallanglinks data from the ParserOutput, which is set by the {{#noexternallanglinks}} parser function.
- Parameters
-
- Returns
- string[] A list of language codes, identifying which repository links to ignore. Empty if {{#noexternallanglinks}} was not used on the page.
◆ handle()
static Wikibase\Client\Hooks\NoLangLinkHandler::handle |
( |
Parser |
$parser, |
|
|
|
$langs |
|
) |
| |
|
static |
Parser function.
- Parameters
-
Parser | $parser | |
| string | ...$langs Language codes or '*' |
◆ $namespaceChecker
Wikibase\Client\Hooks\NoLangLinkHandler::$namespaceChecker |
|
private |
◆ EXTENSION_DATA_KEY
const Wikibase\Client\Hooks\NoLangLinkHandler::EXTENSION_DATA_KEY = 'wikibase-noexternallanglinks' |
The documentation for this class was generated from the following file: