toProjectVersionStatus method

ProjectVersionStatus toProjectVersionStatus()

Implementation

ProjectVersionStatus toProjectVersionStatus() {
  switch (this) {
    case 'TRAINING_IN_PROGRESS':
      return ProjectVersionStatus.trainingInProgress;
    case 'TRAINING_COMPLETED':
      return ProjectVersionStatus.trainingCompleted;
    case 'TRAINING_FAILED':
      return ProjectVersionStatus.trainingFailed;
    case 'STARTING':
      return ProjectVersionStatus.starting;
    case 'RUNNING':
      return ProjectVersionStatus.running;
    case 'FAILED':
      return ProjectVersionStatus.failed;
    case 'STOPPING':
      return ProjectVersionStatus.stopping;
    case 'STOPPED':
      return ProjectVersionStatus.stopped;
    case 'DELETING':
      return ProjectVersionStatus.deleting;
  }
  throw Exception('$this is not known in enum ProjectVersionStatus');
}