NotificationModel.fromJson constructor

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

Implementation

NotificationModel.fromJson(Map<String, dynamic> json) {
  totalSize = json['total_size'];
  limit = json['limit'];
  offset = json['offset'];
  if (json['notifications'] != null) {
    notifications = <Notifications>[];
    json['notifications'].forEach((v) {
      notifications?.add(Notifications.fromJson(v));
    });
  }
}