Is it possible to implement a search in the array for the text typed in EditText? In the adapter, I have a filter that finds the typed text in an ArrayList, creates a new ArrayList, and inserts data there
public void filter(String query) { mFilteredCheeses = new ArrayList<>(); for (String cheese : mDefaultCheeses) { if(cheese.toLowerCase().contains(query.toLowerCase())) { mFilteredCheeses.add(cheese); } } notifyDataSetChanged(); } Can I do the same thing, but with an array of String []
new String[mFilteredCheeses.size()]- I. Smirnov