fromJson method

Lyric fromJson(
  1. Map json
)

Implementation

Lyric fromJson(Map json) {
  Lyric data = Lyric();
  if (json['lyric'] != null) {
    data.lyric = json['lyric'].toString();
  }
  if (json['startTime'] != null) {
    data.startTime = Duration(milliseconds: json['startTime']);
  }
  if (json['endTime'] != null) {
    data.endTime = Duration(milliseconds: json['endTime']);
  }
  if (json['isRemark'] != null) {
    data.isRemark = json['isRemark'];
  }
  return data;
}