Model.fromJson constructor

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

Creates an instance from json.

Implementation

Model.fromJson(Map<String, dynamic> json)
    : id = json[idKey],
      userId = json[userIdKey],
      data = json[dataKey];