EncryptedCalendarItem.fromJSON constructor
EncryptedCalendarItem.fromJSON(
- Map<String, dynamic> data
)
Implementation
factory EncryptedCalendarItem.fromJSON(Map<String, dynamic> data) {
return EncryptedCalendarItem(
(data["id"] as String),
rev: (data["rev"] as String?),
created: (data["created"] as int?),
modified: (data["modified"] as int?),
author: (data["author"] as String?),
responsible: (data["responsible"] as String?),
medicalLocationId: (data["medicalLocationId"] as String?),
tags: (data["tags"] as List<dynamic>).map((x0) => CodeStub.fromJSON(x0) ).toSet(),
codes: (data["codes"] as List<dynamic>).map((x0) => CodeStub.fromJSON(x0) ).toSet(),
endOfLife: (data["endOfLife"] as int?),
deletionDate: (data["deletionDate"] as int?),
title: (data["title"] as String?),
calendarItemTypeId: (data["calendarItemTypeId"] as String?),
masterCalendarItemId: (data["masterCalendarItemId"] as String?),
patientId: (data["patientId"] as String?),
important: (data["important"] as bool?),
homeVisit: (data["homeVisit"] as bool?),
phoneNumber: (data["phoneNumber"] as String?),
placeId: (data["placeId"] as String?),
address: data["address"] == null ? null : EncryptedAddress.fromJSON(data["address"]),
addressText: (data["addressText"] as String?),
startTime: (data["startTime"] as int?),
endTime: (data["endTime"] as int?),
confirmationTime: (data["confirmationTime"] as int?),
cancellationTimestamp: (data["cancellationTimestamp"] as int?),
confirmationId: (data["confirmationId"] as String?),
duration: (data["duration"] as int?),
allDay: (data["allDay"] as bool?),
details: (data["details"] as String?),
wasMigrated: (data["wasMigrated"] as bool?),
agendaId: (data["agendaId"] as String?),
hcpId: (data["hcpId"] as String?),
recurrenceId: (data["recurrenceId"] as String?),
meetingTags: (data["meetingTags"] as List<dynamic>).map((x0) => CalendarItemTag.fromJSON(x0) ).toSet(),
flowItem: data["flowItem"] == null ? null : FlowItem.fromJSON(data["flowItem"]),
secretForeignKeys: (data["secretForeignKeys"] as List<dynamic>).map((x0) => (x0 as String) ).toSet(),
cryptedForeignKeys: (data["cryptedForeignKeys"] as Map<String, dynamic>).map((k0, v0) => MapEntry((k0 as String), (v0 as List<dynamic>).map((x1) => Delegation.fromJSON(x1) ).toSet())),
delegations: (data["delegations"] as Map<String, dynamic>).map((k0, v0) => MapEntry((k0 as String), (v0 as List<dynamic>).map((x1) => Delegation.fromJSON(x1) ).toSet())),
encryptionKeys: (data["encryptionKeys"] as Map<String, dynamic>).map((k0, v0) => MapEntry((k0 as String), (v0 as List<dynamic>).map((x1) => Delegation.fromJSON(x1) ).toSet())),
encryptedSelf: (data["encryptedSelf"] as Base64String?),
securityMetadata: data["securityMetadata"] == null ? null : SecurityMetadata.fromJSON(data["securityMetadata"]),
);
}