ClusterOperationInfo.fromJson constructor

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

Implementation

factory ClusterOperationInfo.fromJson(Map<String, dynamic> json) {
  return ClusterOperationInfo(
    clientRequestId: json['clientRequestId'] as String?,
    clusterArn: json['clusterArn'] as String?,
    creationTime: timeStampFromJson(json['creationTime']),
    endTime: timeStampFromJson(json['endTime']),
    errorInfo: json['errorInfo'] != null
        ? ErrorInfo.fromJson(json['errorInfo'] as Map<String, dynamic>)
        : null,
    operationArn: json['operationArn'] as String?,
    operationState: json['operationState'] as String?,
    operationSteps: (json['operationSteps'] as List?)
        ?.whereNotNull()
        .map((e) => ClusterOperationStep.fromJson(e as Map<String, dynamic>))
        .toList(),
    operationType: json['operationType'] as String?,
    sourceClusterInfo: json['sourceClusterInfo'] != null
        ? MutableClusterInfo.fromJson(
            json['sourceClusterInfo'] as Map<String, dynamic>)
        : null,
    targetClusterInfo: json['targetClusterInfo'] != null
        ? MutableClusterInfo.fromJson(
            json['targetClusterInfo'] as Map<String, dynamic>)
        : null,
  );
}