title: Filter a listview with multiple spinners?
body: <p>This code is a <code>listview</code> that shows the items in the <code>exercises[]</code> string. You can also search through these items with the <code>EditText</code> inputSearch and charsequence, and it detects what list item is selected by comparing strings.</p>
  
  <p><strong>What I need is:</strong>
  A way to filter the listview (String exercises[]) by using multiple spinners?</p>
  
  <p><strong>Full Code:</strong> </p>
  
  <pre><code>public class CalExercises extends Activity {
      private ListView myListView;
      ArrayAdapter&lt;String&gt; myAdapter;
      EditText inputSearch;
  
  
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_calexercise);
          String exercises[] = {"Wall Pushup", "Knees Pushup", "Regular Pushup", "Pullup"};
          myListView = (ListView) findViewById(R.id.exp_list);
          inputSearch = (EditText) findViewById(R.id.itemSearch);
          myAdapter = new ArrayAdapter&lt;String&gt;(this, R.layout.parent_layout, R.id.parent_txt, exercises);
          myListView.setAdapter(myAdapter);
          myListView.setOnItemClickListener(new AdapterView.OnItemClickListener() {
  
              @Override
              public void onItemClick(AdapterView&lt;?&gt; arg0, View arg1, int arg2, long arg3) {
  
                  String PosItem = (String) arg0.getItemAtPosition(arg2);
  
                  Intent itemIntent = new Intent(getBaseContext(), TempCalEx.class);
                  String exIntent = "";
  
                  if ("Wall Pushup".equals(PosItem))
                      exIntent = "wallpushup";
                  else if ("Knees Pushup".equals(PosItem))
                      exIntent = "kneepushup";
                  else if ("Regular Pushup".equals(PosItem)) {
                      exIntent = "regpushup";
                      Toast.makeText(CalExercises.this, "List Detect Test Success - Pushup", Toast.LENGTH_LONG).show();
                  } else if ("Pullup".equals(PosItem)) {
                      exIntent = "pullup";
                      Toast.makeText(CalExercises.this, "List Detect Test Success - Pullup", Toast.LENGTH_LONG).show();
                  }
  
                  itemIntent.putExtra("exString", exIntent);
                  startActivity(itemIntent);
  
  
                  ;
                  inputSearch.addTextChangedListener(new TextWatcher() {
                      @Override
                      public void onTextChanged(CharSequence cs, int arg1, int arg2, int arg3) {
                          CalExercises.this.myAdapter.getFilter().filter(cs);
                      }
  
                      @Override
                      public void beforeTextChanged(CharSequence arg0, int arg1, int arg2,
                                                    int arg3) {
                      }
  
                      @Override
                      public void afterTextChanged(Editable arg0) {
                      }
                  });
  
  
              }
  
              ;
  
          });
  
      }}
  </code></pre>