#[non_exhaustive]pub struct NumberRequest<'r> {
pub value: &'r str,
pub style: NumberStyle<'r>,
pub neutral: bool,
pub digits: DigitOptions,
pub sign: SignDisplay,
pub grouping: Grouping,
pub ordinal: bool,
}Expand description
A number for a NumberFormatter (the host’s,
Host::numbers). Built by the runtime; a host
reads it.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.value: &'r strThe exact value in plain neutral digits, unrounded, no exponent
(-1234.5, 0.001, -0): Intl.NumberFormat v3 formats such a
string exactly. Unscaled for NumberStyle::Percent (the style
multiplies by 100); a plural request, or a neutral one for an exact
key, carries the value selection sees (× 100 for :percent).
style: NumberStyle<'r>Decimal, percent, currency or unit.
neutral: boolThe core’s neutral output — ASCII digits, ., -/+, no grouping —
instead of the locale’s symbols (in the browser: locale en,
numberingSystem: "latn", useGrouping: false).
digits: DigitOptionsThe digit options, resolved.
sign: SignDisplaysignDisplay.
grouping: GroupinguseGrouping (a neutral request never groups).
ordinal: boolselect=ordinal: the plural rules’ type for
NumberFormatter::plural.