迅捷3
func countryName(from countryCode: String) -> String { if let name = (Locale.current as NSLocale).displayName(forKey: .countryCode, value: countryCode) { // Country name was found return name } else { // Country name cannot be found return countryCode }}
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)