是否有与 XQuery/XPath 等效的 JSON?
在复杂的 JSON 数组和哈希中搜索项目时,例如:
When searching for items in complex JSON arrays and hashes, like:
[
{ "id": 1, "name": "One", "objects": [
{ "id": 1, "name": "Response 1", "objects": [
// etc.
}]
}
]
是否有某种查询语言可用于在 [0].objects where id = 3 中查找项目 ?
Is there some kind of query language I can used to find an item in [0].objects where id = 3
?
推荐答案
是的,它叫做 JSONPath:
它还集成到 DOJO 中.
相关文章