PersonMatch.fromJson constructor

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

Implementation

factory PersonMatch.fromJson(Map<String, dynamic> json) {
  return PersonMatch(
    faceMatches: (json['FaceMatches'] as List?)
        ?.whereNotNull()
        .map((e) => FaceMatch.fromJson(e as Map<String, dynamic>))
        .toList(),
    person: json['Person'] != null
        ? PersonDetail.fromJson(json['Person'] as Map<String, dynamic>)
        : null,
    timestamp: json['Timestamp'] as int?,
  );
}