Action.fromJson constructor
Implementation
factory Action.fromJson(Map<String, dynamic> json) {
return Action(
actionId: json['ActionId'] as String,
actionThreshold: ActionThreshold.fromJson(
json['ActionThreshold'] as Map<String, dynamic>),
actionType: (json['ActionType'] as String).toActionType(),
approvalModel: (json['ApprovalModel'] as String).toApprovalModel(),
budgetName: json['BudgetName'] as String,
definition:
Definition.fromJson(json['Definition'] as Map<String, dynamic>),
executionRoleArn: json['ExecutionRoleArn'] as String,
notificationType:
(json['NotificationType'] as String).toNotificationType(),
status: (json['Status'] as String).toActionStatus(),
subscribers: (json['Subscribers'] as List)
.whereNotNull()
.map((e) => Subscriber.fromJson(e as Map<String, dynamic>))
.toList(),
);
}