Add iOS
This commit is contained in:
26
ios/Parsers/AVAuthorizationStatus+descriptor.swift
Normal file
26
ios/Parsers/AVAuthorizationStatus+descriptor.swift
Normal file
@@ -0,0 +1,26 @@
|
||||
//
|
||||
// AVAuthorizationStatus+descriptor.swift
|
||||
// Cuvent
|
||||
//
|
||||
// Created by Marc Rousavy on 29.12.20.
|
||||
// Copyright © 2020 Facebook. All rights reserved.
|
||||
//
|
||||
|
||||
import AVFoundation
|
||||
|
||||
extension AVAuthorizationStatus {
|
||||
var descriptor: String {
|
||||
switch self {
|
||||
case .authorized:
|
||||
return "authorized"
|
||||
case .denied:
|
||||
return "denied"
|
||||
case .notDetermined:
|
||||
return "not-determined"
|
||||
case .restricted:
|
||||
return "restricted"
|
||||
@unknown default:
|
||||
fatalError("AVAuthorizationStatus has unknown state.")
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user