printMilliseconds function

String printMilliseconds(
  1. Duration duration, {
  2. bool terse = false,
  3. DurationLocale language = const EnglishDurationLocale(),
  4. String separator = ' ',
  5. bool abbreviated = false,
})

Pretty print duration in terms of milliseconds.

If terse is true, microseconds are ignored. Use language to configure which locale to print for. Use abbreviated to control if the units should be abbreviated.

Implementation

String printMilliseconds(Duration duration,
    {bool terse = false,
    DurationLocale language = const EnglishDurationLocale(),
    String separator = ' ',
    bool abbreviated = false}) {
  final String fmt = prettyMilliseconds(duration,
      terse: terse,
      language: language,
      separator: separator,
      abbreviated: abbreviated);
  print(fmt);
  return fmt;
}