write method

  1. @override
void write(
  1. BinaryWriter writer,
  2. AppleHealthElement obj
)
override

Is called when a value has to be encoded.

Implementation

@override
void write(BinaryWriter writer, AppleHealthElement obj) {
  writer
    ..writeByte(14)
    ..writeByte(0)
    ..write(obj.id)
    ..writeByte(1)
    ..write(obj.value)
    ..writeByte(2)
    ..write(obj.date)
    ..writeByte(3)
    ..write(obj.synced)
    ..writeByte(4)
    ..write(obj.syncedDate)
    ..writeByte(5)
    ..write(obj.dateFrom)
    ..writeByte(6)
    ..write(obj.dateTo)
    ..writeByte(7)
    ..write(obj.type)
    ..writeByte(8)
    ..write(obj.healthValue)
    ..writeByte(9)
    ..write(obj.deviceId)
    ..writeByte(10)
    ..write(obj.sourceId)
    ..writeByte(11)
    ..write(obj.platform)
    ..writeByte(12)
    ..write(obj.uuid)
    ..writeByte(13)
    ..write(obj.deviceName);
}