MigrationTask.fromJson constructor

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

Implementation

factory MigrationTask.fromJson(Map<String, dynamic> json) {
  return MigrationTask(
    migrationTaskName: json['MigrationTaskName'] as String?,
    progressUpdateStream: json['ProgressUpdateStream'] as String?,
    resourceAttributeList: (json['ResourceAttributeList'] as List?)
        ?.whereNotNull()
        .map((e) => ResourceAttribute.fromJson(e as Map<String, dynamic>))
        .toList(),
    task: json['Task'] != null
        ? Task.fromJson(json['Task'] as Map<String, dynamic>)
        : null,
    updateDateTime: timeStampFromJson(json['UpdateDateTime']),
  );
}