MediaWiki REL1_39
LanguageHsb.php
Go to the documentation of this file.
1<?php
23
29class LanguageHsb extends Language {
38 public function convertGrammar( $word, $case ) {
39 $grammarForms =
40 MediaWikiServices::getInstance()->getMainConfig()->get( MainConfigNames::GrammarForms );
41 if ( isset( $grammarForms['hsb'][$case][$word] ) ) {
42 return $grammarForms['hsb'][$case][$word];
43 }
44
45 switch ( $case ) {
46 case 'instrumental': # instrumental
47 $word = 'z ' . $word;
48 break;
49 case 'lokatiw': # lokatiw
50 $word = 'wo ' . $word;
51 break;
52 }
53
54 # this will return the original value for 'nominatiw' (nominativ) and
55 # all undefined case values.
56 return $word;
57 }
58}
Upper Sorbian (Hornjoserbsce)
convertGrammar( $word, $case)
Convert from the nominative form of a noun to some other case Invoked with {{grammar:case|word}}.
Base class for language-specific code.
Definition Language.php:53
A class containing constants representing the names of configuration variables.
Service locator for MediaWiki core services.