toWorkflowExecutionTerminatedCause method

WorkflowExecutionTerminatedCause toWorkflowExecutionTerminatedCause()

Implementation

WorkflowExecutionTerminatedCause toWorkflowExecutionTerminatedCause() {
  switch (this) {
    case 'CHILD_POLICY_APPLIED':
      return WorkflowExecutionTerminatedCause.childPolicyApplied;
    case 'EVENT_LIMIT_EXCEEDED':
      return WorkflowExecutionTerminatedCause.eventLimitExceeded;
    case 'OPERATOR_INITIATED':
      return WorkflowExecutionTerminatedCause.operatorInitiated;
  }
  throw Exception(
      '$this is not known in enum WorkflowExecutionTerminatedCause');
}