Home | History | Annotate | Download | only in i18n

Lines Matching refs:rule

355                                  const NFRule* rule,
370 // throw an exception if the rule is a negative number
371 // rule
372 if (rule->getBaseValue() == NFRule::kNegativeNumberRule) {
373 // throw new IllegalArgumentException("<< not allowed in negative-number rule");
378 // if the rule is a fraction rule, return an
380 else if (rule->getBaseValue() == NFRule::kImproperFractionRule
381 || rule->getBaseValue() == NFRule::kProperFractionRule
382 || rule->getBaseValue() == NFRule::kMasterRule) {
386 // if the rule set containing the rule is a fraction
387 // rule set, return a NumeratorSubstitution
389 return new NumeratorSubstitution(pos, (double)rule->getBaseValue(),
395 return new MultiplierSubstitution(pos, rule->getDivisor(), ruleSet,
401 // if the rule is a negative-number rule, return
403 if (rule->getBaseValue() == NFRule::kNegativeNumberRule) {
407 // if the rule is a fraction rule, return a
409 else if (rule->getBaseValue() == NFRule::kImproperFractionRule
410 || rule->getBaseValue() == NFRule::kProperFractionRule
411 || rule->getBaseValue() == NFRule::kMasterRule) {
415 // if the rule set owning the rule is a fraction rule set,
418 // throw new IllegalArgumentException(">> not allowed in fraction rule set");
425 return new ModulusSubstitution(pos, rule->getDivisor(), predecessor,
467 // (i.e., "<<" or ">>"), it uses the rule set it belongs to to
472 // if the description contains a rule set name, that's the rule
474 // names rule set
502 // usual rule-search process and always uses the rule that precedes
503 // it in its own rule set's rule list (this is used for place-value
575 // either the name of the rule set it uses, or the pattern of
600 * @param pos The position in toInsertInto where the owning rule's
601 * rule text begins (this value is added to this substitution's
610 // rule set's format() method to format the result
634 * @param pos The position in toInsertInto where the owning rule's
635 * rule text begins (this value is added to this substitution's
649 // if the result isn't an integer, then call either our rule set's
673 * Parses a string using the rule set or DecimalFormat belonging
685 * @param upperBound When searching the rule set for a rule
712 // figure out the highest base value a rule can have and match
717 // it was, and the others allow any rule to match
720 // use our rule set to parse the text. If that fails and
752 // the caller (this is either the owning rule's base value
754 // owning rule's base value with its other substitution's
760 // on the types of substitutions: For a regular rule, the
762 // times the rule's divisor (or the rule's base value) plus
764 // supersede part of the rule's base value). For a negative-
765 // number rule, the result is the negative of its substitution's
766 // result. For a fraction rule, it's the sum of its two
767 // substitution results. For a rule in a fraction rule set,
769 // the rule's base value. Results from same-value substitutions
804 * Represented by == in rule descriptions.
839 * A substitution that divides the number being formatted by the its rule's
841 * regular rule.
856 // the owning rule's divisor controls the behavior of this
857 // substitution: rather than keeping a backpointer to the rule,
868 // circuits the rule-search process and goes straight to the
869 // specified rule to format the substitution value
894 * @param pos The position of the rule text in toInsertInto
900 // of this function (which uses either a rule set or a DecimalFormat
905 // a >>> substitution goes straight to a particular rule to
919 * @param pos The position of the rule text in toInsertInto
925 // of this function (which uses either a rule set or a DecimalFormat
930 // a >>> substitution goes straight to a particular rule to
966 // use the specific rule's doParse() method, and then we have to
992 // either the name of the rule set it uses, or the pattern of
1019 * it marks the rule set it calls (if any) as a fraction rule set.
1051 * at a time using the rule set containing this substitution.
1056 * @param pos The position of the owning rule's rule text in
1071 // as an integer using this substitution's owning rule set
1154 // using this substitution's owning rule set (we do this by setting
1257 rule set's