toCbor method

List<int> toCbor()
inherited

Serialize command to CBOR bytes

Implementation

List<int> toCbor() {
  final map = toMap();
  final cborMap = CborMap(map
      .map((key, value) => MapEntry(CborString(key), _toCborValue(value))));
  return cborEncode(cborMap);
}