MediaWiki  REL1_24
LanguageSl.php
Go to the documentation of this file.
00001 <?php
00029 class LanguageSl extends Language {
00030     # Convert from the nominative form of a noun to some other case
00031     # Invoked with {{GRAMMAR:case|word}}
00032 
00040     function convertGrammar( $word, $case ) {
00041         global $wgGrammarForms;
00042         if ( isset( $wgGrammarForms['sl'][$case][$word] ) ) {
00043             return $wgGrammarForms['sl'][$case][$word];
00044         }
00045 
00046         switch ( $case ) {
00047             case 'mestnik': # locative
00048                 $word = 'o ' . $word;
00049                 break;
00050             case 'orodnik': # instrumental
00051                 $word = 'z ' . $word;
00052                 break;
00053         }
00054 
00055         # this will return the original value for 'imenovalnik' (nominativ) and
00056         # all undefined case values.
00057         return $word;
00058     }
00059 }