Skip to content

PhoneCall

A phone call, as listed in a PhoneLog.

Annotations

Constructors

PhoneCall.fromCallLogEntry

PhoneCall.fromCallLogEntry(
  1. CallLogEntry call
)

Creates a PhoneCall from a CallLogEntry from the call log plugin.

PhoneCall.fromJson

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

PhoneCall

PhoneCall([
  1. DateTime? timestamp,
  2. String? callType,
  3. int? duration,
  4. String? formattedNumber,
  5. String? number,
  6. String? name,
])

Properties

callType

String? callType
getter/setter pair

Type of call. One of:

  • answered_externally
  • incoming
  • blocked
  • missed
  • outgoing
  • rejected
  • voice_mail
  • unknown

duration

int? duration
getter/setter pair

Duration of the call in seconds, as reported by the Android call log.

formattedNumber

String? formattedNumber
getter/setter pair

The formatted version of the phone number (if available).

name

String? name
getter/setter pair

The name of the caller (if available).

number

String? number
getter/setter pair

The phone number.

timestamp

DateTime? timestamp
getter/setter pair

Date and time of the call.

Methods

toJson

Map<String, dynamic> toJson()