HomeSort by relevance Sort by last modified time
    Searched refs:PluralType (Results 1 - 25 of 45) sorted by null

1 2

  /external/cldr/tools/java/org/unicode/cldr/tool/
PluralMinimalPairs.java 17 import com.ibm.icu.text.PluralRules.PluralType;
20 private Map<PluralType, Map<PluralInfo.Count, String>> typeToCountToSample = new EnumMap<>(PluralType.class);
48 PluralType type = "pluralMinimalPairs".equals(element) ? PluralType.CARDINAL
49 : "ordinalMinimalPairs".equals(element) ? PluralType.ORDINAL
52 parts.getAttributeValue(-1, type == PluralType.CARDINAL ? "count" : "ordinal"));
70 public void put(String locale, PluralType type, Count count, String sample) {
78 public String get(PluralType type, Count count) {
83 public Set<Count> getCounts(PluralType type)
    [all...]
GeneratePluralConfirmation.java 20 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
29 private static final com.ibm.icu.text.PluralRules.PluralType ICU_ORDINAL = com.ibm.icu.text.PluralRules.PluralType.ORDINAL;
41 for (PluralRules.PluralType type : PluralRules.PluralType.values()) {
51 + (type == PluralRules.PluralType.CARDINAL ? "plural" : "ordinal")
53 + (type == PluralRules.PluralType.CARDINAL ? "count" : "ordinal")
65 // SUPPLEMENTAL.getPluralLocales(PluralType.ordinal)
114 for (PluralType type : PluralType.values())
    [all...]
PluralRulesFactory.java 21 import com.ibm.icu.text.PluralRules.PluralType;
81 public PluralRules forLocale(ULocale locale, PluralType ordinal) {
107 // public PluralRules forLocale(ULocale locale, PluralType ordinal) {
108 // PluralRules override = ordinal != PluralType.CARDINAL
148 return supplementalDataInfo.getPluralLocales(SupplementalDataInfo.PluralType.cardinal);
151 public Set<Count> getSampleCounts(String locale, PluralType type) {
156 public static String getSamplePattern(String uLocale, PluralType type, Count count) {
199 // PluralType type = "pluralMinimalPairs".equals(element) ? PluralType.CARDINAL
200 // : "ordinalMinimalPairs".equals(element) ? PluralType.ORDINA
    [all...]
ShowPlurals.java 20 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
102 Set<String> cardinalLocales = supplementalDataInfo.getPluralLocales(PluralType.cardinal);
103 Set<String> ordinalLocales = supplementalDataInfo.getPluralLocales(PluralType.ordinal);
129 for (PluralType pluralType : PluralType.values()) {
130 if (pluralType == PluralType.ordinal && !ordinalLocales.contains(locale)
131 || pluralType == PluralType.cardinal && !cardinalLocales.contains(locale))
    [all...]
WritePluralRulesSpreadsheets.java 31 import com.ibm.icu.text.PluralRules.PluralType;
71 TreeSet<String> localesWithPlurals = new TreeSet<>(supplemental.getPluralLocales(SupplementalDataInfo.PluralType.cardinal));
112 if (samplePatterns.isEmpty(PluralType.CARDINAL)) {
148 String sample = samplePatterns.get(PluralType.CARDINAL, Count.valueOf(cat));
156 String sample2 = samplePatterns.get(PluralType.CARDINAL, Count.valueOf(keyword));
179 if (samplePatterns.isEmpty(PluralType.CARDINAL)) {
215 return samplePatterns.get(PluralType.CARDINAL, Count.valueOf(start));
WritePluralRules.java 13 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
24 for (String locale : sInfo.getPluralLocales(PluralType.cardinal)) {
36 formatPluralHeader(PluralType.cardinal, "WritePluralRules"));
102 public static String formatPluralHeader(PluralType type, String filename) {
FindPluralDifferences.java 15 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
65 for (PluralType pluralType : PluralType.values()) {
66 Set<String> oldLocales = supplementalOld.getPluralLocales(pluralType);
67 Set<String> newLocales = supplementalNew.getPluralLocales(pluralType);
77 System.out.println("\nNew locales for " + pluralType + "s:\t" + justNewLocales.size() + "\t" + justNewLocales);
82 PluralInfo oldPluralInfo = supplementalOld.getPlurals(pluralType, locale);
84 PluralInfo newPluralInfo = supplementalNew.getPlurals(pluralType, locale);
113 System.out.println(pluralType
    [all...]
GeneratedPluralSamples.java 26 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
373 String decimalsString = type == PluralType.ordinal ? "" : decimals.toString();
386 if (type != PluralType.ordinal) {
442 private final PluralType type;
444 GeneratedPluralSamples(PluralInfo pluralInfo, PluralType type) {
451 if (type == PluralType.cardinal) {
569 for (PluralType type : PluralType.values()) {
571 out = FileUtilities.openUTF8Writer(MyOptions.output.option.getValue(), type == PluralType.cardinal ? "plurals.xml" : "ordinals.xml");
593 : new TreeSet<Entry<PluralInfo, Set<String>>>(new HackComparator(type == PluralType.cardina
    [all...]
VerifyAttributeValues.java 28 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
95 localeSpecific.put(LocaleSpecific.pluralCardinal, supplementalData.getPlurals(PluralType.cardinal, locale).getPluralRules().getKeywords());
96 localeSpecific.put(LocaleSpecific.pluralOrdinal, supplementalData.getPlurals(PluralType.ordinal, locale).getPluralRules().getKeywords());
  /external/icu/android_icu4j/src/main/tests/android/icu/dev/test/format/
PluralRulesFactory.java 13 import android.icu.text.PluralRules.PluralType;
32 public PluralRules forLocale(ULocale locale, PluralType ordinal) {
PluralFormatUnitTest.java 33 import android.icu.text.PluralRules.PluralType;
97 PluralFormat de_fee_1 = new PluralFormat(ULocale.GERMAN, PluralType.CARDINAL, "other{fee}");
98 PluralFormat de_fee_2 = new PluralFormat(ULocale.GERMAN, PluralType.CARDINAL, "other{fee}");
99 PluralFormat de_fi = new PluralFormat(ULocale.GERMAN, PluralType.CARDINAL, "other{fi}");
100 PluralFormat fr_fee = new PluralFormat(ULocale.FRENCH, PluralType.CARDINAL, "other{fee}");
380 PluralFormat pf = new PluralFormat(ULocale.ENGLISH, PluralType.ORDINAL, pattern);
385 // Code coverage: Use the other new-for-PluralType constructor as well.
386 pf = new PluralFormat(ULocale.ENGLISH, PluralType.ORDINAL);
392 pf = new PluralFormat(Locale.ENGLISH, PluralType.ORDINAL);
PluralRulesTest.java 51 import android.icu.text.PluralRules.PluralType;
    [all...]
  /external/icu/icu4j/main/tests/core/src/com/ibm/icu/dev/test/format/
PluralRulesFactory.java 12 import com.ibm.icu.text.PluralRules.PluralType;
31 public PluralRules forLocale(ULocale locale, PluralType ordinal) {
PluralFormatUnitTest.java 32 import com.ibm.icu.text.PluralRules.PluralType;
94 PluralFormat de_fee_1 = new PluralFormat(ULocale.GERMAN, PluralType.CARDINAL, "other{fee}");
95 PluralFormat de_fee_2 = new PluralFormat(ULocale.GERMAN, PluralType.CARDINAL, "other{fee}");
96 PluralFormat de_fi = new PluralFormat(ULocale.GERMAN, PluralType.CARDINAL, "other{fi}");
97 PluralFormat fr_fee = new PluralFormat(ULocale.FRENCH, PluralType.CARDINAL, "other{fee}");
377 PluralFormat pf = new PluralFormat(ULocale.ENGLISH, PluralType.ORDINAL, pattern);
382 // Code coverage: Use the other new-for-PluralType constructor as well.
383 pf = new PluralFormat(ULocale.ENGLISH, PluralType.ORDINAL);
389 pf = new PluralFormat(Locale.ENGLISH, PluralType.ORDINAL);
PluralRulesTest.java 50 import com.ibm.icu.text.PluralRules.PluralType;
    [all...]
  /external/cldr/tools/java/org/unicode/cldr/icu/
PluralsMapper.java 9 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
46 fillType(PluralType.cardinal, icuData);
47 fillType(PluralType.ordinal, icuData);
51 private void fillType(PluralType type, IcuData icuData) {
53 String filename = type == PluralType.cardinal ? "plurals.xml" : "ordinals.xml";
67 public PluralsHandler(PluralType type, IcuData icuData) {
69 prefix = type == PluralType.cardinal ? "/locales/" : "/locales_ordinals/";
  /external/icu/android_icu4j/src/main/java/android/icu/text/
PluralFormat.java 25 import android.icu.text.PluralRules.PluralType;
190 init(null, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null);
200 init(null, PluralType.CARDINAL, ulocale, null);
222 init(rules, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null);
234 init(rules, PluralType.CARDINAL, ulocale, null);
256 public PluralFormat(ULocale ulocale, PluralType type) {
267 public PluralFormat(Locale locale, PluralType type) {
280 init(null, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null);
297 init(null, PluralType.CARDINAL, ulocale, null);
312 init(rules, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null)
    [all...]
  /external/icu/icu4j/main/classes/core/src/com/ibm/icu/text/
PluralFormat.java 24 import com.ibm.icu.text.PluralRules.PluralType;
191 init(null, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null);
202 init(null, PluralType.CARDINAL, ulocale, null);
226 init(rules, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null);
239 init(rules, PluralType.CARDINAL, ulocale, null);
263 public PluralFormat(ULocale ulocale, PluralType type) {
275 public PluralFormat(Locale locale, PluralType type) {
289 init(null, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null);
307 init(null, PluralType.CARDINAL, ulocale, null);
323 init(rules, PluralType.CARDINAL, ULocale.getDefault(Category.FORMAT), null)
    [all...]
  /external/cldr/tools/cldr-unittest/src/org/unicode/cldr/unittest/
TestPluralRuleGeneration.java 10 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
55 for (PluralType type : SupplementalDataInfo.PluralType.values()) {
  /external/cldr/tools/java/org/unicode/cldr/util/
PluralSnapshot.java 16 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
77 private SnapshotInfo(PluralType pluralType, Integral integral) {
81 for (String locale : supplementalDataInfo.getPluralLocales(pluralType)) {
82 PluralInfo plurals = supplementalDataInfo.getPlurals(pluralType, locale);
129 private static final EnumMap<PluralType, EnumMap<Integral, SnapshotInfo>> SINGLETONS = new EnumMap<PluralType, EnumMap<Integral, SnapshotInfo>>(
130 PluralType.class);
132 SINGLETONS.put(PluralType.cardinal, new EnumMap<Integral, SnapshotInfo>(Integral.class));
133 SINGLETONS.put(PluralType.ordinal, new EnumMap<Integral, SnapshotInfo>(Integral.class))
    [all...]
CoreCoverageInfo.java 17 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
121 if (sdi.getPluralLocales(PluralType.cardinal).contains(baseLanguage)) {
126 if (sdi.getPluralLocales(PluralType.ordinal).contains(baseLanguage)) {
LogicalGrouping.java 12 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
183 return supplementalData.getPlurals(PluralType.cardinal,
207 String pluralType = parts.getAttributeValue(-1, "count");
208 if (pluralType.equals("0") || pluralType.equals("1")) return true;
209 if (!pluralType.equals("zero") && !pluralType.equals("one")) return false;
225 pluralRules, pluralType, 0, explicits, true);
  /external/icu/android_icu4j/src/main/java/android/icu/impl/
PluralRulesLoader.java 23 import android.icu.text.PluralRules.PluralType;
51 Set<String> keys = getLocaleIdToRulesIdMap(PluralType.CARDINAL).keySet();
66 Map<String, String> idMap = getLocaleIdToRulesIdMap(PluralType.CARDINAL);
70 String rulesId = getRulesIdForLocale(locale, PluralType.CARDINAL);
87 private Map<String, String> getLocaleIdToRulesIdMap(PluralType type) {
89 return (type == PluralType.CARDINAL) ? localeIdToCardinalRulesId : localeIdToOrdinalRulesId;
166 public String getRulesIdForLocale(ULocale locale, PluralType type) {
239 public PluralRules forLocale(ULocale locale, PluralRules.PluralType type) {
  /external/icu/icu4j/main/classes/core/src/com/ibm/icu/impl/
PluralRulesLoader.java 22 import com.ibm.icu.text.PluralRules.PluralType;
49 Set<String> keys = getLocaleIdToRulesIdMap(PluralType.CARDINAL).keySet();
64 Map<String, String> idMap = getLocaleIdToRulesIdMap(PluralType.CARDINAL);
68 String rulesId = getRulesIdForLocale(locale, PluralType.CARDINAL);
85 private Map<String, String> getLocaleIdToRulesIdMap(PluralType type) {
87 return (type == PluralType.CARDINAL) ? localeIdToCardinalRulesId : localeIdToOrdinalRulesId;
164 public String getRulesIdForLocale(ULocale locale, PluralType type) {
237 public PluralRules forLocale(ULocale locale, PluralRules.PluralType type) {
  /external/cldr/tools/java/org/unicode/cldr/test/
CheckCoverage.java 20 import org.unicode.cldr.util.SupplementalDataInfo.PluralType;
122 PluralInfo pluralInfo = supplementalData.getPlurals(PluralType.cardinal, localeID);
123 if (pluralInfo == supplementalData.getPlurals(PluralType.cardinal, "root")) {

Completed in 275 milliseconds

1 2