title: Parsing JSON array with a sub-array with GSON?
body: <p>Say I have a JSON string like:</p>
  
  <p><code>{"title":"aaa","url":"bbb","image":{"url":"ccc","width":"100","height":"200"}, ...</code></p>
  
  <p>My accessor:</p>
  
  <pre><code>import com.google.gson.annotations.SerializedName;
  
  public class accessorClass {
  
      @SerializedName("title")
      private String title;
  
      @SerializedName("url")
      private String url;
  
      @SerializedName("image")
      private String image;
  
      // how do I place the sub-arrays for the image here?
      ...
  
  
      public final String get_title() {
          return this.title;
      }
  
      public final String get_url() {
          return this.url;
      }
  
      public final String get_image() {
          return this.image;
      }
  
      ...
  
  }
  </code></pre>
  
  <p>And my main:</p>
  
  <pre><code>            Gson gson = new Gson();
              JsonParser parser = new JsonParser();
              JsonArray Jarray = parser.parse(jstring).getAsJsonArray();
  
              ArrayList&lt;accessorClass &gt; aens = new ArrayList&lt;accessorClass &gt;();
  
              for(JsonElement obj : Jarray )
              {
                  accessorClass ens = gson.fromJson( obj , accessorClass .class);
                  aens.add(ens);
              }
  </code></pre>
  
  <p>What do you think would be the best way to get those sub-arrays for the image here?</p>