Package com.ibm.icu.text
Class PluralRules.Factory
- java.lang.Object
-
- com.ibm.icu.text.PluralRules.Factory
-
- Enclosing class:
- PluralRules
@Deprecated public abstract static class PluralRules.Factory extends java.lang.Object
Deprecated.This API is ICU internal only.Provides a factory for returning plural rules
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
Factory()
Deprecated.This API is ICU internal only.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description PluralRules
forLocale(ULocale locale)
Deprecated.This API is ICU internal only.abstract PluralRules
forLocale(ULocale locale, PluralRules.PluralType type)
Deprecated.This API is ICU internal only.abstract ULocale[]
getAvailableULocales()
Deprecated.This API is ICU internal only.static com.ibm.icu.impl.PluralRulesLoader
getDefaultFactory()
Deprecated.This API is ICU internal only.abstract ULocale
getFunctionalEquivalent(ULocale locale, boolean[] isAvailable)
Deprecated.This API is ICU internal only.abstract boolean
hasOverride(ULocale locale)
Deprecated.This API is ICU internal only.
-
-
-
Method Detail
-
forLocale
@Deprecated public abstract PluralRules forLocale(ULocale locale, PluralRules.PluralType type)
Deprecated.This API is ICU internal only.Provides access to the predefinedPluralRules
for a given locale and the plural type.ICU defines plural rules for many locales based on CLDR Language Plural Rules. For these predefined rules, see CLDR page at http://unicode.org/repos/cldr-tmp/trunk/diff/supplemental/language_plural_rules.html
- Parameters:
locale
- The locale for which aPluralRules
object is returned.type
- The plural type (e.g., cardinal or ordinal).- Returns:
- The predefined
PluralRules
object for this locale. If there's no predefined rules for this locale, the rules for the closest parent in the locale hierarchy that has one will be returned. The final fallback always returns the default rules.
-
forLocale
@Deprecated public final PluralRules forLocale(ULocale locale)
Deprecated.This API is ICU internal only.Utility for getting CARDINAL rules.- Parameters:
locale
- the locale- Returns:
- plural rules.
-
getAvailableULocales
@Deprecated public abstract ULocale[] getAvailableULocales()
Deprecated.This API is ICU internal only.Returns the locales for which there is plurals data.
-
getFunctionalEquivalent
@Deprecated public abstract ULocale getFunctionalEquivalent(ULocale locale, boolean[] isAvailable)
Deprecated.This API is ICU internal only.Returns the 'functionally equivalent' locale with respect to plural rules. Calling PluralRules.forLocale with the functionally equivalent locale, and with the provided locale, returns rules that behave the same.
All locales with the same functionally equivalent locale have plural rules that behave the same. This is not exaustive; there may be other locales whose plural rules behave the same that do not have the same equivalent locale.- Parameters:
locale
- the locale to checkisAvailable
- if not null and of length > 0, this will hold 'true' at index 0 if locale is directly defined (without fallback) as having plural rules- Returns:
- the functionally-equivalent locale
-
getDefaultFactory
@Deprecated public static com.ibm.icu.impl.PluralRulesLoader getDefaultFactory()
Deprecated.This API is ICU internal only.Returns the default factory.
-
hasOverride
@Deprecated public abstract boolean hasOverride(ULocale locale)
Deprecated.This API is ICU internal only.Returns whether or not there are overrides.
-
-