toHex method

List<String> toHex({
  1. String prefix = '0x',
})

Returns a List of the hexadecimal strings of each element.

Each hexadecimal string will be converted to uppercase and will be optionally prefixed with prefix.

Implementation

List<String> toHex({String prefix = '0x'}) => [
      for (var byte in this) '$prefix${byte.toRadixString(16).toUpperCase()}',
    ];