title: Android json parsing object inside another object and array
body: <p>I want parse all "name" and "desc" from this json object inside another json object. i need another "for"? </p>
  
  <pre><code> {
    "main": {
      "details": [
        {
          "owner_name": "owner_name1",
          "id": "id1",
          "details2": {
            "data": [
              {
                "name": "name1",
                "desc": "my desc1",
  
              },
              {
                "name": "name2",
                "desc": "my desc2",
  
              }
            ],
  
          }
        },
        {
          "owner_name": "owner_name2",
          "id": "id2",
          "details2": {
            "data": [
              {
                "name": "name3",
                "desc": "my desc3",
  
              },
              {
                "name": "name4",
                "desc": "my desc4",
  
              }
            ]
          }
        }
      ]
    }
  }
  </code></pre>
  
  <p>and My java Code is:</p>
  
  <pre><code>JSONObject jsono = new JSONObject(data);
  JSONObject mainObject = jsono.getJSONObject("main");
  JSONArray jsonArray = mainObject.getJSONArray("details");
  
  for (int i = 0; i &lt; jsonArray.length(); i++) {
      JSONObject object1 = jsonArray.getJSONObject(i);
  
       JSONObject objectDetails2 = object1.getJSONObject("details2");
       JSONArray jsonArrayData = objectDetails2.getJSONArray("data");
  
     for (int j = 0; j &lt; jsonArrayData.length(); j++) {
           JSONObject object = jsonArrayData.getJSONObject(j);   
           Actors actor = new Actors();
      actor.setName(object.getString("name"));
      actor.setDesc(object.getString("desc"));
  
  
      actorsList.add(actor);
  
        }
  </code></pre>
  
  <p>It only show First "data" result inside details2 not showing second details2 inside data..
  Now my result is: "name1,dmy desc1,name2,my desc2"</p>
  
  <p>i want all result like : "name1,dmy desc1,name2,my desc2,name3,my desc3,name4,my desc4"</p>