經過 objc_setAssociatedObject (關聯) 的形式實現爲Category (類別) 添加屬性

先了解一下 objc_setAssociatedObject  objc_getAssociatedObjecthtml 須要頭文件 #import <objc/runtime.h>ios objc_setAssociatedObjectapp Sets an associated value for a given object using a given key and association
相關文章
相關標籤/搜索