HI,
我有一个 JSON 解析的返回对象集。
{
"word":[
"offered",
"postings"
],
"annotation":[
["offered highlighted","this is also given as annotation","This annotation has been added here currently","offering new annotation points","\"offered\" is in the sense of languages"],
["my postings","this is new annotation for postings.","my postings","this is posting annotation.... Working for the feature of the annotation."]
],
"user":[
["","","vinoth","Anonymous","Vinoth"],
["Anonymous","vinoth","Anonymous","Arputharaj"]
],
"id":[
["58","60","61","63","68"],
["32","57","59","62"]
],
"comment":
{
"id58":["first comment","This is a old comment for this annotation","Next level of commenting.","Fourth comment to this annotation","testing"],
"id61":["this is an old annotation.\r\nMy comment is very bad about this.","Second comment to this annotation"],
"id57":["I want to add one more comment to this"]
},
"commentUser":{
"id58":["vinoth","Anonymous","Vinothkumar","Vinothkumar","vinoth"],
"id61":["Anonymous","Commentor"],
"id57":["vinoth"]
}
}
我想知道每个对象和数组的长度。
我用过.length
得到的长度annotation[0].length
。我得到了预期的结果,即:5。“用户”和“id”也是如此。
但我没有得到“word”、“id58”、“id61”等的长度......
我也想知道长度comment
& commentUser
.
请帮助我。