NotificationTypeNewPushMessage.fromJson constructor

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

Parses a NotificationTypeNewPushMessage from TDLib JSON.

Implementation

factory NotificationTypeNewPushMessage.fromJson(Map<String, dynamic> json) =>
    NotificationTypeNewPushMessage(
      messageId: _readInt(json['message_id']),
      senderId: _readObject(json['sender_id'], MessageSender.fromJson),
      senderName: _readString(json['sender_name']),
      isOutgoing: _readBool(json['is_outgoing']),
      content: _readObject(json['content'], PushMessageContent.fromJson),
    );