Ivar imgIvar = class_getInstanceVariable([self class], "_propertyName");
UIImage *img = object_getIvar(self, imgIvar);
Ivar imgIvar = class_getInstanceVariable([self class], "_propertyName");
UIImage *img = object_getIvar(self, imgIvar);
本文标题:OC 通过字符串获取类的属性
本文链接:https://www.haomeiwen.com/subject/xskjuktx.html
网友评论