class DeviceNetwork { DeviceNetwork({ this.description, this.errorCode, this.data, this.errorMsg,}); DeviceNetwork.fromJson(dynamic json) { description = json['description']; errorCode = json['errorCode']; data = json['data'] != null ? DeviceNetworkInfo.fromJson(json['data']) : null; errorMsg = json['errorMsg']; } String? description; int? errorCode; DeviceNetworkInfo? data; String? errorMsg; Map toJson() { final map = {}; map['description'] = description; map['errorCode'] = errorCode; if (data != null) { map['data'] = data!.toJson(); } map['errorMsg'] = errorMsg; return map; } } class DeviceNetworkInfo { DeviceNetworkInfo({ this.wifiName, this.networkMac, this.secretKey, this.peerId, }); DeviceNetworkInfo.fromJson(dynamic json) { wifiName = json['wifiName']; networkMac = json['networkMac']; secretKey = json['secretKey']; peerId = json['peerId']; } String? wifiName; String? networkMac; String? secretKey; String? peerId; Map toJson() { final map = {}; map['wifiName'] = wifiName; map['networkMac'] = networkMac; map['secretKey'] = secretKey; map['peerId'] = peerId; return map; } }