WWLocationManager

main

Find location-related settings on your phone. (Region / Language / SIM / GPS)
William-Weng/WWLocationManager

WWLocationManager

Swift-5.6 iOS-14.0 TAG Swift Package Manager-SUCCESS LICENSE

WWLocationManager

dependencies: [
    .package(url: "https://github.com/William-Weng/WWLocationManager.git", .upToNextMajor(from: "1.0.0"))
]

Function - 可用函式

函式 功能
countryCode(isAlways:result:failure:) 取得有關所在位置的資訊 (Info.plist => NSLocationWhenInUseUsageDescription)
close() 關閉定位

Example - 程式範例

import UIKit
import WWPrint
import WWLocationManager

final class ViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        
        WWLocationManager.shared.countryCode { code in
            wwPrint(code)
        } failure: { error in
            wwPrint(error)
        }
    }
}

Description

  • Swift Tools 5.6.0
View More Packages from this Author

Dependencies

  • None
Last updated: Sun Oct 20 2024 09:17:35 GMT-0900 (Hawaii-Aleutian Daylight Time)