Struct intl_pluralrules::operands::PluralOperands[][src]

pub struct PluralOperands {
    pub n: f64,
    pub i: isize,
    pub v: isize,
    pub w: isize,
    pub f: isize,
    pub t: isize,
}

A full plural operands representation of a number. See CLDR Plural Rules for complete operands description.

Fields

Absolute value of input

Integer value of input

Number of visible fraction digits with trailing zeros

Number of visible fraction digits without trailing zeros

Visible fraction digits with trailing zeros

Visible fraction digits without trailing zeros

Methods

impl PluralOperands
[src]

Given numerical input (as numeric type or reference), returns the PluralOperands representation of the input.

Example

use intl_pluralrules::operands::*;
assert_eq!(Ok(PluralOperands {
   n: 123.45_f64,
   i: 123,
   v: 2,
   w: 2,
   f: 45,
   t: 45,
}), PluralOperands::from(123.45))

Trait Implementations

impl Debug for PluralOperands
[src]

Formats the value using the given formatter. Read more

impl PartialEq for PluralOperands
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations