convert method
Converts input
and returns the result of the conversion.
Implementation
@override
String convert(List<int> bytes) {
StringBuffer buffer = new StringBuffer();
for (int part in bytes) {
if (part & 0xff != part) {
throw new FormatException("Non-byte integer detected");
}
buffer.write('${part < 16 ? '0' : ''}${part.toRadixString(16)}');
}
if(upperCase) {
return buffer.toString().toUpperCase();
} else {
return buffer.toString();
}
}