title: Have ArrayAdapter with list of objects to show objects containing string in a ListView
body: <p>I have a normal ListView:</p>
  
  <pre><code>&lt;ListView
  android:id="@android:id/list"
  android:layout_width="fill_parent"
  android:layout_height="wrap_content"
  android:dividerHeight="10dp" /&gt;
  </code></pre>
  
  <p>And I populate that listview with an ArrayList of Alert objects:</p>
  
  <pre><code>// Get ListView object from XML
  listView = (ListView) findViewById(android.R.id.list);
  
  // Create a new Adapter
  ArrayAdapter&lt;Alert&gt; adapter = new ArrayAdapter&lt;Alert&gt;(this, android.R.layout.activity_list_item, android.R.id.text1, DataSourceHandler.getAlertsList());
  
  // Assign adapter to ListView
  listView.setAdapter(adapter);
  </code></pre>
  
  <p>DataSourceHandler.getAlertsList() returns to me the ArrayList of objects and in my ListView I now see two items like this:</p>
  
  <ul>
  <li>path.to.object@41a92a48</li>
  <li>path.to.object@41a92cc8</li>
  </ul>
  
  <p>Those two Alert objects has a method called getName() which returns a String that I want to use as the displaying name for this item in the list instead of what I get above.</p>
  
  <p>How can I do this?</p>