static final UnicodeSet ALLOWED_ID = new UnicodeSet("[a-z]").freeze();
// TODO Remove RulesList by moving its API and fields into PluralRules.
- /**
- * @internal
- * @deprecated This API is ICU internal only.
- */
- @Deprecated
- public static final String CATEGORY_SEPARATOR = "; ";
- /**
- * @internal
- * @deprecated This API is ICU internal only.
- */
- @Deprecated
- public static final String KEYWORD_RULE_SEPARATOR = ": ";
+
+ private static final String CATEGORY_SEPARATOR = "; ";
private static final long serialVersionUID = 1;
/**
* Provides a factory for returning plural rules
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public static abstract class Factory {
/**
* Sole constructor
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* @return The predefined <code>PluralRules</code> 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.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* Utility for getting CARDINAL rules.
* @param locale the locale
* @return plural rules.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Returns the locales for which there is plurals data.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* 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
* @return the functionally-equivalent locale
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Returns the default factory.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Returns whether or not there are overrides.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public static final PluralRules DEFAULT = new PluralRules(new RuleList().addRule(DEFAULT_RULE));
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* The double value of the entire number.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* The integer value, with the fraction digits truncated off.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* All visible fraction digits as an integer, including trailing zeros.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Visible fraction digits as an integer, not including trailing zeros.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Number of visible fraction digits.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Number of visible fraction digits, not including trailing zeros.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* <p>For example, "j is 3" is equivalent to "i is 3 and v is 0": it matches
* "3" but not "3.1" or "3.0".
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* An interface to FixedDecimal, allowing for other implementations.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* Returns the value corresponding to the specified operand (n, i, f, t, v, or w).
* If the operand is 'n', returns a double; otherwise, returns an integer.
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public double getPluralOperand(Operand operand);
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public boolean isNaN();
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
private final int baseFactor;
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
static final long MAX = (long)1E18;
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
* @param n is the original number
* @param v number of digits to the right of the decimal place. e.g 1.00 = 2 25. = 0
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* Return a guess as to the number of decimals that would be displayed. This is only a guess; callers should
* always supply the decimals explicitly if possible. Currently, it is up to 6 decimals (without trailing zeros).
* Returns 0 for infinities and nans.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*
*/
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* {@inheritDoc}
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Override
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* We're not going to care about NaN.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Override
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* {@inheritDoc}
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* {@inheritDoc}
*
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* Selection parameter for either integer-only or decimal-only.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public enum SampleType {
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
INTEGER,
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* A range of NumberInfo that includes all values with the same visibleFractionDigitCount.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public static class FixedDecimalRange {
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public final FixedDecimal start;
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public final FixedDecimal end;
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
this.end = end;
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
/**
* A list of NumberInfo that includes all values with the same visibleFractionDigitCount.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public static class FixedDecimalSamples {
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public final SampleType sampleType;
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
public final Set<FixedDecimalRange> samples;
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
*
* @param number The number for which the rule has to be determined.
* @return The keyword of the selected rule.
- * @internal
+ * @internal Visible For Testing
* @deprecated This API is ICU internal only.
*/
@Deprecated
*
* @param number The number information for which the rule has to be determined.
* @return The keyword of the selected rule.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
*
* @param sample The number information for which the rule has to be determined.
* @param keyword The keyword to filter on
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* @return the values that trigger this keyword, or null. The returned collection
* is immutable. It will be empty if the keyword is not defined.
*
- * @internal
+ * @internal Visible For Testing
* @deprecated This API is ICU internal only.
*/
@Deprecated
* @param keyword the keyword to test
* @param sampleType the type of samples requested, INTEGER or DECIMAL
* @return a list of values matching the keyword.
- * @internal
+ * @internal CLDR
* @deprecated ICU internal only
*/
@Deprecated
return result.size() == 0 ? null : Collections.unmodifiableSet(result);
}
- /**
- * @internal
- * @deprecated This API is ICU internal only.
- */
- @Deprecated
- public boolean addSample(String keyword, Number sample, int maxCount, Set<Double> result) {
+ private boolean addSample(String keyword, Number sample, int maxCount, Set<Double> result) {
String selectedKeyword = sample instanceof FixedDecimal ? select((FixedDecimal)sample) : select(sample.doubleValue());
if (selectedKeyword.equals(keyword)) {
result.add(sample.doubleValue());
* @param keyword the keyword to test
* @param sampleType the type of samples requested, INTEGER or DECIMAL
* @return a list of values matching the keyword.
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
* @param uniqueValue
* If non null, set to the unique value.
* @return the KeywordStatus
- * @internal
+ * @internal Visible For Testing
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated This API is ICU internal only.
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated internal
*/
@Deprecated
return toString().compareTo(other.toString());
}
- /**
- * @internal
- * @deprecated internal
- */
- @Deprecated
- public Boolean isLimited(String keyword) {
+ Boolean isLimited(String keyword) {
return rules.isLimited(keyword, SampleType.INTEGER);
}
/**
- * @internal
+ * @internal Visible For Testing
* @deprecated internal
*/
@Deprecated
}
/**
- * @internal
+ * @internal CLDR
* @deprecated internal
*/
@Deprecated