
通过
mj_enumerateProperties
方法可以获取到类的所有属性名,MJ使用MJProperty
对属性名进行了包装,让其作为自己的一个属性。我们可以通过
property.type.code
与一些字符串进行比较,从而知道基本数据类型的属性具体是什么类型的。
上面提到的code从哪来?

mj_enumerateProperties
方法可以获取到类的所有属性名,MJ使用MJProperty
对属性名进行了包装,让其作为自己的一个属性。property.type.code
与一些字符串进行比较,从而知道基本数据类型的属性具体是什么类型的。本文标题:看MJExtension源码之判断基本数据类型
本文链接:https://www.haomeiwen.com/subject/ncpdortx.html
网友评论