84 * "one: n is 1; few: n in 2..4"
92 * "zero: n is 0; one: n is 1; zero: n mod 100 in 1..19"
98 * "one: n is 1; few: n mod 10 in 2..4 and n mod 100 not in 12..14"
107 * Syntax:
108 * \code 109 * rules = rule (';' rule)* 110 * rule = keyword ':' condition 111 * keyword = 112 * condition = and_condition ('or' and_condition)* 113 * and_condition = relation ('and' relation)* 114 * relation = is_relation | in_relation | within_relation | 'n' 115 * is_relation = expr 'is' ('not')? value 116 * in_relation = expr ('not')? 'in' range_list 117 * within_relation = expr ('not')? 'within' range 118 * expr = ('n' | 'i' | 'f' | 'v' | 'j') ('mod' value)? 119 * range_list = (range | value) (',' range_list)* 120 * value = digit+ ('.' digit+)? 121 * digit = 0|1|2|3|4|5|6|7|8|9 122 * range = value'..'value 123 * \endcode 124 *
126 *
127 * The i, f, and v values are defined as follows: 128 *
136 * Examples are in the following table: 137 *
177 * The difference between 'in' and 'within' is that 'in' only includes integers in the specified range, while 'within' 178 * includes all values. Using 'within' with a range_list consisting entirely of values is the same as using 'in' (it's 179 * not an error). 180 *
185 * The difference between 'in' and 'within' is that 'in' only includes 186 * integers in the specified range, while 'within' includes all values. 187 * Using 'within' with a range_list consisting entirely of values is the 188 * same as using 'in' (it's not an error). 189 *
191 * Keywords 192 * could be defined by users or from ICU locale data. There are 6 193 * predefined values in ICU - 'zero', 'one', 'two', 'few', 'many' and 194 * 'other'. Callers need to check the value of keyword returned by 195 * {@link #select} method. 196 *
199 * UnicodeString keyword = pl->select(number); 200 * if (keyword== UnicodeString("one") { 201 * ... 202 * } 203 * else if ( ... ) 204 *
207 * ICU defines plural rules for many locales based on CLDR Language Plural Rules. 208 * For these predefined rules, see CLDR page at 209 * https://unicode-org.github.io/cldr-staging/charts/latest/supplemental/language_plural_rules.html 210 *
PluralRules