ExclusionPreview.fromJson constructor
ExclusionPreview.fromJson(
- Map<String, dynamic> json
)
Implementation
factory ExclusionPreview.fromJson(Map<String, dynamic> json) {
return ExclusionPreview(
description: json['description'] as String,
recommendation: json['recommendation'] as String,
scopes: (json['scopes'] as List)
.whereNotNull()
.map((e) => Scope.fromJson(e as Map<String, dynamic>))
.toList(),
title: json['title'] as String,
attributes: (json['attributes'] as List?)
?.whereNotNull()
.map((e) => Attribute.fromJson(e as Map<String, dynamic>))
.toList(),
);
}