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
3namespace MediaWiki\Interwiki\Hook;
4
5/**
6 * This is a hook handler interface, see docs/Hooks.md.
7 * Use the hook name "InterwikiLoadPrefix" to register handlers implementing this interface.
8 *
9 * @deprecated since 1.36, does not support enumerating all valid prefixes; for testing
10 *    purposes (re)set $wgInterwikiCache instead.
11 * @stable to implement
12 * @ingroup Hooks
13 */
14interface InterwikiLoadPrefixHook {
15    /**
16     * This hook is called when resolving whether a given prefix is an interwiki or not.
17     *
18     * @since 1.35
19     *
20     * @param string $prefix Interwiki prefix we are looking for
21     * @param array &$iwData Output array describing the interwiki with keys iw_url, iw_local,
22     *   iw_trans and optionally iw_api and iw_wikiid
23     * @return bool|void True (or no return value) without providing an interwiki to continue
24     *   interwiki search, or false to abort
25     */
26    public function onInterwikiLoadPrefix( $prefix, &$iwData );
27}