CallEventResult.fromMap constructor

CallEventResult.fromMap(
  1. Map resultMap
)

Implementation

CallEventResult.fromMap(Map resultMap) {
  direction = resultMap[keyDirection] == 'INCOMING'
      ? CallDirection.incoming
      : CallDirection.outgoing;

  callDetails = CallDetails.fromMap(resultMap[keyCallDetails] ?? {});

  callEvent = CallEvent.fromString(resultMap[keyCallEvent] ?? '');
}