{
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users('c-480b-9f29-27b4de54c85b')/drive/items('01QZDPV46NIERRXLPDDRHIYT4HGDYL2CZS')/workbook/worksheets('Sheet123')/tables('1')/rows",
"value": [
{
"@odata.id": "/users('9af3784f-924c-480b-9f29-27b4de54c85b')/drive/items('01QZDPV46NIERRXLPDDRHIYT4HGDYL2CZS')/workbook/worksheets(%27%7B77104C57-F2DA-49CE-B55C-9D7D458A%7D%27)/tables(%271%27)/rows/itemAt(index=0)",
"index": 0,
"values": [
[
100,
"fname1",
"lname1",
123,
"fname1@gmail"
]
]
},
{
"@odata.id": "/users('9a24c-480b-9f29-27b4de54c85b')/drive/items('01QZDPVYT4HGDYL2CZS')/workbook/worksheets(%27%7B77104C57-F2DA-49CED458A%7D%27)/tables(%271%27)/rows/itemAt(index=1)",
"index": 1,
"values": [
[
102,
"fname2",
"lname2",
345,
"[email protected]"
]
]
}
]
}
我试图提取“值”:[[102,“fname2”,“lname2”,345,“fname2 @gmail.com”]:在json响应中。
JSON-java库易于使用。
import org.json.*;
JSONObject obj = new JSONObject(jsonStr);
Object values = obj.getJSONArray("value").getJSONObject(0).getJSONArray("values");