NotificationSound.fromJson constructor

NotificationSound.fromJson(
  1. Map<String, dynamic> json
)

Parses a NotificationSound from TDLib JSON.

Implementation

factory NotificationSound.fromJson(Map<String, dynamic> json) =>
    NotificationSound(
      id: _readInt(json['id']),
      duration: _readInt(json['duration']),
      date: _readInt(json['date']),
      title: _readString(json['title']),
      data: _readString(json['data']),
      sound: _readObject(json['sound'], File.fromJson),
      extra: json['@extra'],
      clientId: _readClientId(json['@client_id']),
    );