42 'translatewiki.net' =>
'n',
90 $lord = strtolower( $word );
92 if ( preg_match(
'/wiki$/', $lord ) ) {
95 if ( isset( self::$familygender[$lord] ) ) {
96 $gender = self::$familygender[$lord];
98 $case =
' ' . strtolower( $case );
99 if ( preg_match(
'/ [is]/', $case ) ) {
100 # däm WikiMaatplaz singe, dä Wikipeedija iere, däm Wikiwööterbooch singe
101 # dem/em WikiMaatplaz singe, de Wikipeedija iere, dem/em Wikiwööterbooch singe
102 # däm WikiMaatplaz sing, dä Wikipeedija ier, däm Wikiwööterbooch sing
103 # dem/em WikiMaatplaz sing, de Wikipeedija ier, dem/em Wikiwööterbooch sing
104 $word = ( preg_match(
'/ b/', $case )
105 ? ( $gender ==
'f' ?
'dä' :
'däm' )
106 : ( $gender ==
'f' ?
'de' :
'dem' )
107 ) .
' ' . $word .
' ' .
108 ( $gender ==
'f' ?
'ier' :
'sing' ) .
109 ( preg_match(
'/ m/', $case ) ?
'e' :
''
111 } elseif ( preg_match(
'/ e/', $case ) ) {
112 # en dämm WikiMaatPlaz, en dä Wikipeedija, en dämm Wikiwööterbooch
113 # em WikiMaatplaz, en de Wikipeedija, em Wikiwööterbooch
114 if ( preg_match(
'/ b/', $case ) ) {
115 $word =
'en ' . ( $gender ==
'f' ?
'dä' :
'däm' ) .
' ' . $word;
117 $word = ( $gender ==
'f' ?
'en de' :
'em' ) .
' ' . $word;
119 } elseif ( preg_match(
'/ [fv]/', $case ) || preg_match(
'/ [2jg]/', $case ) ) {
120 # vun däm WikiMaatplaz, vun dä Wikipeedija, vun däm Wikiwööterbooch
121 # vum WikiMaatplaz, vun de Wikipeedija, vum Wikiwööterbooch
122 if ( preg_match(
'/ b/', $case ) ) {
123 $word =
'vun ' . ( $gender ==
'f' ?
'dä' :
'däm' ) .
' ' . $word;
125 $word = ( $gender ==
'f' ?
'vun de' :
'vum' ) .
' ' . $word;
127 } elseif ( preg_match(
'/ [3d]/', $case ) ) {
128 # dämm WikiMaatPlaz, dä Wikipeedija, dämm Wikiwööterbooch
129 # dem/em WikiMaatplaz, de Wikipeedija, dem/em Wikiwööterbooch
130 if ( preg_match(
'/ b/', $case ) ) {
131 $word = ( $gender ==
'f' ?
'dää' :
'dämm' ) .
' ' . $word;
133 $word = ( $gender ==
'f' ?
'de' :
'dem' ) .
' ' . $word;
136 # dä WikiMaatPlaz, di Wikipeedija, dat Wikiwööterbooch
137 # der WikiMaatplaz, de Wikipeedija, et Wikiwööterbooch
138 if ( preg_match(
'/ b/', $case ) ) {
161 $word = $lord .
' ' . $word;
176 if ( is_string( $forms ) ) {
179 if ( !count( $forms ) ) {
186 } elseif ( $count == 0 ) {
convertPlural( $count, $forms)
Handle cases of (1, other, 0) or (1, other)
convertGrammar( $word, $case)
Convert from the nominative form of a noun to other cases.
Internationalisation code See https://www.mediawiki.org/wiki/Special:MyLanguage/Localisation for more...
preConvertPlural($forms, $count)
Checks that convertPlural was given an array and pads it to requested amount of forms by copying the ...
handleExplicitPluralForms( $count, array $forms)
Handles explicit plural forms for Language::convertPlural()