- All Implemented Interfaces:
- PluralRule, Localizable
- Direct Known Subclasses:
- DefaultRule_af, DefaultRule_am, DefaultRule_ar, DefaultRule_az, DefaultRule_be, DefaultRule_bg, DefaultRule_bh, DefaultRule_bn, DefaultRule_bo, DefaultRule_bs, DefaultRule_ca, DefaultRule_cs, DefaultRule_cy, DefaultRule_da, DefaultRule_de, DefaultRule_dz, DefaultRule_el, DefaultRule_en, DefaultRule_eo, DefaultRule_es, DefaultRule_et, DefaultRule_eu, DefaultRule_fa, DefaultRule_fi, DefaultRule_fil, DefaultRule_fo, DefaultRule_fr, DefaultRule_fur, DefaultRule_fy, DefaultRule_ga, DefaultRule_gl, DefaultRule_gu, DefaultRule_guw, DefaultRule_ha, DefaultRule_he, DefaultRule_hi, DefaultRule_hr, DefaultRule_hu, DefaultRule_id, DefaultRule_is, DefaultRule_it, DefaultRule_ja, DefaultRule_jv, DefaultRule_ka, DefaultRule_km, DefaultRule_kn, DefaultRule_ko, DefaultRule_ku, DefaultRule_lb, DefaultRule_ln, DefaultRule_lt, DefaultRule_lv, DefaultRule_mg, DefaultRule_mk, DefaultRule_ml, DefaultRule_mn, DefaultRule_mr, DefaultRule_ms, DefaultRule_mt, DefaultRule_nah, DefaultRule_nb, DefaultRule_ne, DefaultRule_nl, DefaultRule_nn, DefaultRule_no, DefaultRule_nso, DefaultRule_om, DefaultRule_or, DefaultRule_pa, DefaultRule_pap, DefaultRule_pl, DefaultRule_ps, DefaultRule_pt, DefaultRule_pt_br, DefaultRule_ro, DefaultRule_ru, DefaultRule_se, DefaultRule_sk, DefaultRule_sl, DefaultRule_smi, DefaultRule_smj, DefaultRule_sms, DefaultRule_so, DefaultRule_sq, DefaultRule_sr, DefaultRule_sv, DefaultRule_sw, DefaultRule_ta, DefaultRule_te, DefaultRule_th, DefaultRule_ti, DefaultRule_tk, DefaultRule_tr, DefaultRule_uk, DefaultRule_ur, DefaultRule_vi, DefaultRule_wa, DefaultRule_zh, DefaultRule_zu
public class DefaultRule
extends Object
implements Localizable, PluralRule
Default implementation of plural rules. The i18n generator will
substitute subclasses of this class, which may reside anywhere in
the package hierarchy, based on the locale. See Localizable
for more details on this process.
The default implementation here always selects the default form.
To define a new language, simply declare a subclass of this class
that is named with the locale you want to specify, such as
DefaultRule_en_uk for English spoken in the UK (note the lower-cased
tag).
This is an implementation of the language pluralization rules described
at http://translate.sourceforge.net/wiki/l10n/pluralforms
Eventually, all these rules will be machine generated from Unicode's
CLDR, perhaps with some additional data that isn't kept there if
necessary. The current subclasses are defined just to get reasonable
plural support for most of the common languages -- in particular, you
should not rely on particular keywords for the plural forms of a
given language.