MediaWiki master
LanguageHu.php
Go to the documentation of this file.
1<?php
24
30class LanguageHu extends Language {
31
32 public function convertGrammar( $word, $case ) {
33 $grammarForms = MediaWikiServices::getInstance()->getMainConfig()
34 ->get( MainConfigNames::GrammarForms );
35 if ( isset( $grammarForms[$this->getCode()][$case][$word] ) ) {
36 return $grammarForms[$this->getCode()][$case][$word];
37 }
38
39 switch ( $case ) {
40 case 'rol':
41 return $word . 'ról';
42 case 'ba':
43 return $word . 'ba';
44 case 'k':
45 return $word . 'k';
46 }
47 return '';
48 }
49}
Hungarian localisation for MediaWiki.
convertGrammar( $word, $case)
Grammatical transformations, needed for inflected languages Invoked by putting {{grammar:case|word}} ...
Base class for language-specific code.
Definition Language.php:81
getCode()
Get the internal language code for this language object.
A class containing constants representing the names of configuration variables.
Service locator for MediaWiki core services.