我有一个包含以下示例数据的数组
[{"MissionId":10,"Name":"Test 10!","Description":"Describe 10","MissionStatus":1,"ExpPoint":100,"CreatedDate":"2017-08-07T09:35:17.9882136Z","UserCount":0},{"MissionId":9,"Name":"Test 9!","Description":"Describe 9","MissionStatus":1,"ExpPoint":100,"CreatedDate":"2017-08-07T09:35:12.1392938Z","UserCount":0}]
我可以在控制台中打印出描述如下: -
po [self.missionArray[0]Description]
但当我尝试使用NSlog时,它会说
No known instance method for selector 'Description'
可能出现什么问题?
答案 0 :(得分:0)
尝试将“说明”替换为“说明”
描述是NSObject类中未定义的函数。所以你最终得到错误 - “没有已知的选择器实例方法'描述'”
description - 在NSObject中定义了选择器。所以它应该适合你。