pub struct Params {
pub digit_separator: char,
pub exponent_separator: char,
pub separator_pattern: Vec<usize>,
pub positions: Vec<Position>,
pub rounding: Option<u32>,
pub symbol: Option<&'static str>,
pub code: Option<&'static str>,
}
Expand description
Group of formatting parameters consumed by Formatter
.
Fields§
§digit_separator: char
The character that separates grouped digits (e.g. 1,000,000)
exponent_separator: char
The character that separates minor units from major units (e.g. 1,000.00)
separator_pattern: Vec<usize>
The grouping pattern that is applied to digits / major units (e.g. 1,000,000 vs 1,00,000)
positions: Vec<Position>
The relative positions of the elements in a currency string (e.g. -$1,000 vs $ -1,000)
rounding: Option<u32>
The number of minor unit digits should remain after Round::HalfEven is applied.
symbol: Option<&'static str>
The symbol of the currency (e.g. $)
code: Option<&'static str>
The currency’s ISO code (e.g. USD)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Params
impl RefUnwindSafe for Params
impl Send for Params
impl Sync for Params
impl Unpin for Params
impl UnwindSafe for Params
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more