toFailureReason method

FailureReason toFailureReason()

Implementation

FailureReason toFailureReason() {
  switch (this) {
    case 'REQUEST_TIMED_OUT':
      return FailureReason.requestTimedOut;
    case 'UNSUPPORTED_ALGORITHM':
      return FailureReason.unsupportedAlgorithm;
    case 'OTHER':
      return FailureReason.other;
  }
  throw Exception('$this is not known in enum FailureReason');
}