toJobStatus method

JobStatus toJobStatus()

Implementation

JobStatus toJobStatus() {
  switch (this) {
    case 'PENDING':
      return JobStatus.pending;
    case 'PROVISIONING':
      return JobStatus.provisioning;
    case 'RUNNING':
      return JobStatus.running;
    case 'FAILED':
      return JobStatus.failed;
    case 'SUCCEED':
      return JobStatus.succeed;
    case 'CANCELLING':
      return JobStatus.cancelling;
    case 'CANCELLED':
      return JobStatus.cancelled;
  }
  throw Exception('$this is not known in enum JobStatus');
}