仅适用于 NSDictionary , NSArray
var response:NSDictionary = [ " Hello " : [ " World " : " Data " ]]
println ( JSONData (response). get ( " Hello.World " )) // Data
response = [ " Hello " : [[ " A " : " B " ],[ " C " : " D " ]]]
println ( JSONData (response). get ( " Hello.0.A " )) // B
var sampleArr:NSArray = [[ " A " : " B " ],[ " C " : " D " ]]
var json = JSONData (sampleArr)
println (json. get (
2021-07-20 15:03:15
1KB
Swift
1