3 * Latin (lingua Latina) specific code.
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 * http://www.gnu.org/copyleft/gpl.html
25 * Latin (lingua Latina)
29 class LanguageLa
extends Language
{
31 * Convert from the nominative form of a noun to some other case
33 * Just used in a couple places for sitenames; special-case as necessary.
34 * Rules are far from complete.
36 * Cases: genitive, accusative, ablative
43 function convertGrammar( $word, $case ) {
44 global $wgGrammarForms;
45 if ( isset( $wgGrammarForms['la'][$case][$word] ) ) {
46 return $wgGrammarForms['la'][$case][$word];
51 // only a few declensions, and even for those mostly the singular only
53 '/u[ms]$/', # 2nd declension singular
54 '/ommunia$/', # 3rd declension neuter plural (partly)
55 '/a$/', # 1st declension singular
56 '/libri$/', '/nuntii$/', '/datae$/', # 2nd declension plural (partly)
57 '/tio$/', '/ns$/', '/as$/', # 3rd declension singular (partly)
58 '/es$/' # 5th declension singular
64 'librorum', 'nuntiorum', 'datorum',
65 'tionis', 'ntis', 'atis',
68 return preg_replace( $in, $out, $word );
70 // only a few declensions, and even for those mostly the singular only
72 '/u[ms]$/', # 2nd declension singular
73 '/a$/', # 1st declension singular
74 '/ommuniam$/', # 3rd declension neuter plural (partly)
75 '/libri$/', '/nuntii$/', '/datam$/', # 2nd declension plural (partly)
76 '/tio$/', '/ns$/', '/as$/', # 3rd declension singular (partly)
77 '/es$/' # 5th declension singular
83 'libros', 'nuntios', 'data',
84 'tionem', 'ntem', 'atem',
87 return preg_replace( $in, $out, $word );
89 // only a few declensions, and even for those mostly the singular only
91 '/u[ms]$/', # 2nd declension singular
92 '/ommunia$/', # 3rd declension neuter plural (partly)
93 '/a$/', # 1st declension singular
94 '/libri$/', '/nuntii$/', '/data$/', # 2nd declension plural (partly)
95 '/tio$/', '/ns$/', '/as$/', # 3rd declension singular (partly)
96 '/es$/' # 5th declension singular
102 'libris', 'nuntiis', 'datis',
103 'tione', 'nte', 'ate',
106 return preg_replace( $in, $out, $word );