RuleBasedPluralizer class.
- Companion
- object
Value members
Constructors
Constructs a pluralizer with an empty list of rules. Use the setters to configure.
Constructs a pluralizer with an empty list of rules. Use the setters to configure.
Constructs a pluralizer that uses a list of rules then an identity [[Pluralizer]]
if none
of the rules match. This is useful to build your own [[Pluralizer]]
from scratch.
Constructs a pluralizer that uses a list of rules then an identity [[Pluralizer]]
if none
of the rules match. This is useful to build your own [[Pluralizer]]
from scratch.
- Value Params
- locale
the locale specifying the language of the pluralizer
- rules
the rules to apply in order
Concrete methods
Converts a noun or pronoun to its plural form.
This method is equivalent to calling pluralize(word, 2)
.
The return value is not defined if this method is passed a plural form.
Converts a noun or pronoun to its plural form.
This method is equivalent to calling pluralize(word, 2)
.
The return value is not defined if this method is passed a plural form.
Converts a noun or pronoun to its plural form for the given number of instances. If
number
is 1, word
is returned unchanged.
The return value is not defined if this method is passed a plural form.
Converts a noun or pronoun to its plural form for the given number of instances. If
number
is 1, word
is returned unchanged.
The return value is not defined if this method is passed a plural form.