format

Function format 

Source
pub fn format<P: TryInto<NumberFormat, Error = FormatError>, T: Into<f64>>(
    pattern: P,
    input: T,
) -> Result<String, FormatError>
Expand description

Format a number to a specific human readable form defined by the format spec pattern. The method takes in a string specifier and a number and returns the string representation of the formatted number.