import Foundation
println("Hello, World!")
class People{
var name:String?
}
//方法扩展
extension People{
func test() -> String{
return "abc"
}
}
let p = People();
var v1 = p.test();
println("v1 is \(v1)")
Swift_8_扩展&类别
最新推荐文章于 2024-09-09 17:16:00 发布