我在运行时收到错误 Swift 动态类型转换失败。解析表中的选项是一个数组
if let objects = objects as? [PFObject] {
for object in objects {
println(object.objectId)
let pf = object as PFObject
let name = pf["Question"] as String
// let data1 = pf["Options"] as? NSData
let jsonData: NSData = pf["Options"] as NSData!
let json = JSON(data: jsonData)
self.myArray = json.arrayObject as Array<String>
println(name)
self.question.text = name
// println(answers1)
}
}