Wikibase
MediaWiki Wikibase extension
|
Service for looking up the languages understood by a user. More...
Public Member Functions | |
getUserSpecifiedLanguages (User $user) | |
Returns a list of languages the user specified in addition to the non-optional interface language. More... | |
getAllUserLanguages (User $user) | |
Collects all languages from all user settings we can reach at this point, in order of preference, duplicates stripped: More... | |
Protected Member Functions | |
getBabelLanguages (User $user) | |
Private Attributes | |
$babelLanguages = [] | |
Service for looking up the languages understood by a user.
The current implementation relies on the Babel extension, but that may change.
Wikibase\Repo\BabelUserLanguageLookup::getAllUserLanguages | ( | User | $user | ) |
Collects all languages from all user settings we can reach at this point, in order of preference, duplicates stripped:
User | $user | The current user. |
Implements Wikibase\Lib\UserLanguageLookup.
|
protected |
User | $user | The current user. |
Wikibase\Repo\BabelUserLanguageLookup::getUserSpecifiedLanguages | ( | User | $user | ) |
Returns a list of languages the user specified in addition to the non-optional interface language.
Note: This can contain language codes not actually valid to MediaWiki or valid at all.
User | $user | The current user. |
Implements Wikibase\Lib\UserLanguageLookup.
|
private |