title: Search implementation in android ExpandableListView that displays only not empty resulting groups
body: <p>I am currently making app that is using <code>ExpandableListView</code> with cursors provided by <code>CursorTreeAdapter</code>. In my DB I have countries and cities of these countries.</p>
  
  <p>Now I want to implement <code>SearchView</code> thanks to which I will be able to search a specific city. The tricky thing is that when I search I want to display only groups(countries) where relevant city is. I don't want to display empty groups.</p>
  
  <p>For now I have <code>Loader</code> of countries in my main Activity and from there the resulting data is inserted inside my <code>CursorTreeAdapter</code> implementation inside which I am loading cities. Currently I only found only <a href="http://www.mysamplecode.com/2012/11/android-expandablelistview-search.html" rel="nofollow">this</a> blog with search in <code>ExpandlableListView</code>, but there isn't implementing any mechanism hiding empty groups.</p>
  
  <p>And that is how my tables look like</p>
  
  <pre><code>Countries table
  |ID|Name
  
  City table
  |ID|countryID|Name
  </code></pre>
  
  <p>Does anyone has any idea how it can be achieved?</p>