toMap method

Map<String, dynamic> toMap()

Convert to map for platform channel communication

Implementation

Map<String, dynamic> toMap() {
  return {
    'deviceAddress': deviceAddress,
    'state': state.name,
    'progressPercent': progressPercent,
    'bytesTransferred': bytesTransferred,
    'totalBytes': totalBytes,
    'error': error,
    'estimatedSecondsRemaining': estimatedSecondsRemaining,
  };
}