{"action":"created","issue":{"url":"https://api.github.com/repos/bblanchon/ArduinoJson/issues/217","labels_url":"https://api.github.com/repos/bblanchon/ArduinoJson/issues/217/labels{/name}","comments_url":"https://api.github.com/repos/bblanchon/ArduinoJson/issues/217/comments","events_url":"https://api.github.com/repos/bblanchon/ArduinoJson/issues/217/events","html_url":"https://github.com/bblanchon/ArduinoJson/issues/217","id":130372137,"number":217,"title":"How to convert JsonArray to Int Array","user":{"login":"mrhieuit","id":17003983,"avatar_url":"https://avatars.githubusercontent.com/u/17003983?v=3","gravatar_id":"","url":"https://api.github.com/users/mrhieuit","html_url":"https://github.com/mrhieuit","followers_url":"https://api.github.com/users/mrhieuit/followers","following_url":"https://api.github.com/users/mrhieuit/following{/other_user}","gists_url":"https://api.github.com/users/mrhieuit/gists{/gist_id}","starred_url":"https://api.github.com/users/mrhieuit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrhieuit/subscriptions","organizations_url":"https://api.github.com/users/mrhieuit/orgs","repos_url":"https://api.github.com/users/mrhieuit/repos","events_url":"https://api.github.com/users/mrhieuit/events{/privacy}","received_events_url":"https://api.github.com/users/mrhieuit/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/bblanchon/ArduinoJson/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-02-01T14:11:48Z","updated_at":"2016-02-02T07:07:17Z","closed_at":null,"body":"I have a Json value, I can parse and get JsonArray nested:\r\n\r\nchar* value =  \"{\\\"id\\\":\\\"01\\\", \\\"data\\\": [1,2,3,4,5,6,7,8,9,10]}\\\";\r\nJsonObject& item = jsonBuffer.parseObject(value);\r\nJsonArray& data= item[\"data\"].asArray();\r\n\r\nNow I want convert data from JsonArray to int[ ]. How I do it?\r\nThanks so much.\r\n"},"comment":{"url":"https://api.github.com/repos/bblanchon/ArduinoJson/issues/comments/178414322","html_url":"https://github.com/bblanchon/ArduinoJson/issues/217#issuecomment-178414322","issue_url":"https://api.github.com/repos/bblanchon/ArduinoJson/issues/217","id":178414322,"user":{"login":"mrhieuit","id":17003983,"avatar_url":"https://avatars.githubusercontent.com/u/17003983?v=3","gravatar_id":"","url":"https://api.github.com/users/mrhieuit","html_url":"https://github.com/mrhieuit","followers_url":"https://api.github.com/users/mrhieuit/followers","following_url":"https://api.github.com/users/mrhieuit/following{/other_user}","gists_url":"https://api.github.com/users/mrhieuit/gists{/gist_id}","starred_url":"https://api.github.com/users/mrhieuit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrhieuit/subscriptions","organizations_url":"https://api.github.com/users/mrhieuit/orgs","repos_url":"https://api.github.com/users/mrhieuit/repos","events_url":"https://api.github.com/users/mrhieuit/events{/privacy}","received_events_url":"https://api.github.com/users/mrhieuit/received_events","type":"User","site_admin":false},"created_at":"2016-02-02T07:07:17Z","updated_at":"2016-02-02T07:07:17Z","body":"Yes, I can do it with for loop and cast for each item to int. However, I think ArduinoJson Library should have method to fast covert like: \r\n\r\nint[] intArray = root[\"data\"].asArray<int>();\r\n\r\nI infer idea from your examable: long time = root[\"time\"].as<long>();"}}