RecentChatData.fromJson constructor
Converts a JSON object into a RecentChatData instance.
Implementation
factory RecentChatData.fromJson(Map<String, dynamic> json) => RecentChatData(
contactType: json["contactType"],
isAdminBlocked: json["isAdminBlocked"],
isBlocked: json["isBlocked"],
isBlockedMe: json["isBlockedMe"],
isBroadCast: json["isBroadCast"],
isChatArchived: json["isChatArchived"],
isPrivateChat: json["isPrivateChat"],
isChatPinned: json["isChatPinned"],
isConversationUnRead: json["isConversationUnRead"],
isGroup: json["isGroup"],
isGroupInOfflineMode: json["isGroupInOfflineMode"],
isItSavedContact: json["isItSavedContact"],
isLastMessageRecalledByUser: json["isLastMessageRecalledByUser"],
isLastMessageSentByMe: json["isLastMessageSentByMe"],
isMuted: json["isMuted"],
isSelected: json["isSelected"],
jid: json["jid"],
lastMessageContent: json["lastMessageContent"],
lastMessageId: json["lastMessageId"],
lastMessageStatus: json["lastMessageStatus"],
lastMessageTime: json["lastMessageTime"],
lastMessageType: json["lastMessageType"],
nickName: json["nickName"],
profileImage: json["profileImage"],
profileName: json["profileName"],
unreadMessageCount: json["unreadMessageCount"],
topicId: json["topicId"],
metaData: json["metaData"] == null
? []
: List<MessageMetaData>.from(
json["metaData"].map((x) => MessageMetaData.fromJson(x))),
);