import 'dart:convert'; class GenericMapperModel { int? totalItemsCount; dynamic data; int? messageStatus; dynamic errorMessage; dynamic errorEndUserMessage; GenericMapperModel({ this.totalItemsCount, this.data, this.messageStatus, this.errorMessage, this.errorEndUserMessage, }); factory GenericMapperModel.fromRawJson(String str) => GenericMapperModel.fromJson(json.decode(str)); String toRawJson() => json.encode(toJson()); factory GenericMapperModel.fromJson(Map json) => GenericMapperModel( totalItemsCount: json["totalItemsCount"], data: json["data"], messageStatus: json["messageStatus"], errorMessage: json["errorMessage"], errorEndUserMessage: json["errorEndUserMessage"], ); Map toJson() => { "totalItemsCount": totalItemsCount, "data": data, "messageStatus": messageStatus, "errorMessage": errorMessage, "errorEndUserMessage": errorEndUserMessage, }; }