I am currently using an AutoCompleteTextView with a list of terms that gives suggestions as a user is typing. However, I want to use a different string algorithm than simply checking if a string contains your search term, that compares how close two strings are (e.g. searching "chcken" should show "chicken").
I have produced a method that takes a string parameter - your search query - and returns a sorted array of strings in the database that match that query based on relevance. How do I let the AutoCompleteTextView use that array? I can't simply attach it to the adapter with every keystroke, because that doesn't change the inherent behavior of the AutoCompleteTextView for only showing elements inside the array that MATCH the string query.