title: Android adapter pass JSON object data?
body: <p>Very new to java and android, but I think I need a layout inflater, I tried to implement it but failed, I erased that code.</p>
  
  <p>I can turn the object into an array of strings and use an <code>ArrayAdapter</code> to loop the layout assigning the strings to a <code>textView</code></p>
  
  <p>So <code>ArrayAdapter</code> is limited </p>
  
  <pre><code>ListAdapter dribbbleFeedAdapter = new ArrayAdapter&lt;String&gt;(MainActivity.this, R.layout.feed_card, R.id.info_text, titleArr);
  </code></pre>
  
  <p>I can only pass in the context, layout, textView, and array of strings.</p>
  
  <p>What I want to do is pass the image and other data into the views of that layout. So my question is how do I build the adapter so that I can assign values from the object to the view id?</p>
  
  <pre><code>public class MainActivity extends AppCompatActivity {
  
    @Override
    protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_main);
  
      // GET Json and use adapter ListView
      Ion.with(this)
              .load("http://api.dribbble.com/shots/everyone")
              .asJsonObject()
              .setCallback(new FutureCallback&lt;JsonObject&gt;() {
                @Override
                public void onCompleted(Exception e, JsonObject result) {
  
                  // SET Titles Array
                  List&lt;String&gt; titles = new ArrayList&lt;String&gt;();
  
                  // BUILD THE ARRAY
                  JsonArray shots = result.getAsJsonArray("shots");
                  for (int i = 0; i &lt; shots.size(); i++) {
                    String title = shots.get(i).getAsJsonObject().get("title").getAsString();
                    titles.add(title);
                  }
                  String[] titleArr = new String[titles.size()];
                  titleArr = titles.toArray(titleArr);
  
                  // TODO: Put more data into the feed_card
                  //dribbbleImage.setImageResource(R.drawable.icon_1);
                  ListAdapter dribbbleFeedAdapter = new ArrayAdapter&lt;String&gt;(MainActivity.this,
                          R.layout.feed_card, R.id.info_text, titleArr);
                  ListView dribbbleDataListView = (ListView) findViewById(R.id.dribbbleFeedListView);
                  dribbbleDataListView.setAdapter(dribbbleFeedAdapter);
                }
              });
  
    }
  
  }
  </code></pre>