serializeData method

void serializeData(
  1. dynamic data
)

Implementation

void serializeData(dynamic data) {
  if (writeExtra(data) == true) {
    return;
  } else if (data is ToCBorable) {
    data.write(this);
  } else if (data is Map) {
    serializeMap(data);
  } else if (data is Iterable) {
    serializeIterable(data);
  } else if (data is int) {
    writeInt(data);
  } else if (data is String) {
    writeString(data);
  } else if (data is double) {
    writeFloat(data);
  } else if (data is bool) {
    writeBool(data);
  } else if (data == null) {
    writeNull();
  } else {
    // ignore: avoid_print
    print('writeMapImpl::Non Iterable RT is ${data.runtimeType.toString()}');
  }
}