MediaWiki REL1_39
LanguageDsb.php
Go to the documentation of this file.
1<?php
24
30class LanguageDsb extends Language {
39 public function convertGrammar( $word, $case ) {
40 $grammarForms =
41 MediaWikiServices::getInstance()->getMainConfig()->get( MainConfigNames::GrammarForms );
42 if ( isset( $grammarForms['dsb'][$case][$word] ) ) {
43 return $grammarForms['dsb'][$case][$word];
44 }
45
46 switch ( $case ) {
47 case 'instrumental': # instrumental
48 $word = 'z ' . $word;
49 // fall-through
50 case 'lokatiw': # lokatiw
51 $word = 'wo ' . $word;
52 break;
53 }
54
55 # this will return the original value for 'nominatiw' (nominativ) and
56 # all undefined case values.
57 return $word;
58 }
59}
Lower Sorbian (Dolnoserbski) specific code.
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.