How do I find all the property keys of a KVC compliant Objective-C object?

后端 未结 5 574
灰色年华
灰色年华 2020-12-13 01:03

Is there a method that returns all the keys for an object conforming to the NSKeyValueCoding protocol?

Something along the lines of [object getPropertyKeys]

5条回答
  •  生来不讨喜
    2020-12-13 01:25

    You need a getPropertyType function. See this post: Get an object attributes list in Objective-C

提交回复
热议问题