formatSigned method

String formatSigned({
  1. bool showPlus = false,
  2. int decimals = 2,
})

Format as a potentially negative value.

Implementation

String formatSigned({
  bool showPlus = false,
  int decimals = 2,
}) {
  final bytesVal = bytes.toDouble();
  final options =
      showPlus ? NegativeValueOptions.delta : NegativeValueOptions.defaults;
  return NegativeByteFormatter.format(bytesVal,
      options: options, decimals: decimals);
}