toStatus method
Implementation
Status toStatus() {
switch (this) {
case 'NOT_STARTED':
return Status.notStarted;
case 'IN_PROGRESS':
return Status.inProgress;
case 'FAILED':
return Status.failed;
case 'COMPLETED':
return Status.completed;
}
throw Exception('$this is not known in enum Status');
}