toHandlerErrorCode method
Implementation
HandlerErrorCode toHandlerErrorCode() {
switch (this) {
case 'NotUpdatable':
return HandlerErrorCode.notUpdatable;
case 'InvalidRequest':
return HandlerErrorCode.invalidRequest;
case 'AccessDenied':
return HandlerErrorCode.accessDenied;
case 'InvalidCredentials':
return HandlerErrorCode.invalidCredentials;
case 'AlreadyExists':
return HandlerErrorCode.alreadyExists;
case 'NotFound':
return HandlerErrorCode.notFound;
case 'ResourceConflict':
return HandlerErrorCode.resourceConflict;
case 'Throttling':
return HandlerErrorCode.throttling;
case 'ServiceLimitExceeded':
return HandlerErrorCode.serviceLimitExceeded;
case 'NotStabilized':
return HandlerErrorCode.notStabilized;
case 'GeneralServiceException':
return HandlerErrorCode.generalServiceException;
case 'ServiceInternalError':
return HandlerErrorCode.serviceInternalError;
case 'NetworkFailure':
return HandlerErrorCode.networkFailure;
case 'InternalFailure':
return HandlerErrorCode.internalFailure;
}
throw Exception('$this is not known in enum HandlerErrorCode');
}