format method

String format(
  1. double? n
)

Implementation

String format(double? n) {
  if (n == null || n.isNaN) {
    return "0";
  } else {
    return noneDecimal(n.toStringAsFixed(fixedLength));
  }
}