wiki.techinc.nl/languages/classes/LanguageSe.php

30 lines
569 B
PHP
Raw Normal View History

<?php
/**
2010-10-10 12:53:37 +00:00
* Northern Sami (Sámegiella)
*
* @ingroup Language
*/
class LanguageSe extends Language {
2011-05-29 15:21:03 +00:00
/**
* @param $count int
* @param $forms array
* @return string
*/
function convertPlural( $count, $forms ) {
if ( !count( $forms ) ) { return ''; }
// plural forms per http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_plural_rules.html#se
$forms = $this->preConvertPlural( $forms, 3 );
if ( $count == 1 ) {
2010-06-13 20:23:53 +00:00
$index = 0;
} elseif ( $count == 2 ) {
2010-06-13 20:23:53 +00:00
$index = 1;
} else {
2010-06-13 20:23:53 +00:00
$index = 2;
}
return $forms[$index];
}
}