(&self)
| 438 | } |
| 439 | |
| 440 | const fn get_separator_interval(&self) -> usize { |
| 441 | match self.format_type { |
| 442 | Some(FormatType::Binary | FormatType::Octal | FormatType::Hex(_)) => 4, |
| 443 | Some( |
| 444 | FormatType::Decimal |
| 445 | | FormatType::FixedPoint(_) |
| 446 | | FormatType::GeneralFormat(_) |
| 447 | | FormatType::Exponent(_) |
| 448 | | FormatType::Percentage |
| 449 | | FormatType::Number(_), |
| 450 | ) => 3, |
| 451 | None => 3, |
| 452 | _ => panic!("Separators only valid for numbers!"), |
| 453 | } |
| 454 | } |
| 455 | |
| 456 | fn add_magnitude_separators(&self, magnitude_str: String, prefix: &str) -> String { |
| 457 | match &self.grouping_option { |
no outgoing calls
no test coverage detected