blob: 89edce11b727abca9fa631826c1ed8fb0cce4007 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
<?php
/**
* Romanian (Română)
*
* @ingroup Language
*/
class LanguageRo extends Language {
function convertPlural( $count, $forms ) {
// Plural rules per
// http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_plural_rules.html#ro
if ( !count( $forms ) ) { return ''; }
$forms = $this->preConvertPlural( $forms, 3 );
if ( $count == 1 ) {
$index = 0;
} elseif ( $count == 0 || $count % 100 < 20 ) {
$index = 1;
} else {
$index = 2;
}
return $forms[$index];
}
}
|