title: How to write custom ExpandableListAdapter
body: <p>I'm looking to write my own <code>ExpandableListAdapter</code> which operates similarly to <code>ArrayAdapter</code>. My data model is this:</p>
  
  <pre><code>public class Group {
  
      private String name;   
  
      private List&lt;Child&gt; children;
  }
  
  public class Child {
  
       private String name;
  }
  </code></pre>
  
  <p>Pretty simple. How can I map this relationship into a <code>ExpandableListAdapter</code> implementation? I have a working <code>SimpleExpandableListAdapter</code> working right now, but I need more custom control over items (displaying icons, etc.). What should I do for this? </p>
  
  <p>The main thing is that I need an <code>add()</code> method to be able to add groups and to invalidate the list when children are added and removed from the adapter. I'm actually surprised that there isn't an implementation in the SDK (even an abstract one) which helps one accomplish this.</p>