format method

String format(
  1. double? n
)

Implementation

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