更新时间:2022-04-18 07:02:27
您可以为包含所有信息的 AutoCompleteTextView 创建自定义适配器,假设您有一个 People(姓名、部门、职位)类.
You can create a custom Adapter for your AutoCompleteTextView which has all the info, say you have a class People(name, department, designation).
类似的东西
autoCompleteTextView.setAdapter(new CustomAdapter<People>(getBaseContext(), android.R.layout.simple_list_item_1, "a list of all your people"))