CallLogEntry.fromJson constructor

CallLogEntry.fromJson(
  1. Map map
)

Implementation

factory CallLogEntry.fromJson(Map map) {
  return CallLogEntry(
    id: map['id'],
    number: map['number'],
    contactName: map['contactName'],
    date: DateTime.tryParse(map['date']),
    duration: Duration(seconds: map['duration'] ?? 0),
    isOutgoing: map['isOutgoing'],
  );
}