callLogsStream property

Stream<List<CallLogEntry>> get callLogsStream

Listen to call logs stream from native Android CallLogEntry is Model Class

Implementation

Stream<List<CallLogEntry>> get callLogsStream {
  return _callLogsChannel.receiveBroadcastStream().map((event) {
    // event is a JSON string
    final List<dynamic> decoded = jsonDecode(event);
    return decoded.map((e) => CallLogEntry.fromMap
      (Map<String, dynamic>.from(e))).toList();
  });
}