直接上代码
public protocol CodingTableKey {
static func crateTB();
}
public protocol TableDecodable {
associatedtype CodingKeys: CodingTableKey
typealias Properties = CodingKeys
}
extension TableDecodable{
static func test(){
self.CodingKeys.crateTB()
}
}
class People: TableDecodable {
enum CodingKeys:CodingTableKey {
static func crateTB() {
}
case name
}
}
网友评论