### Question:
DefaultDropDownSelectionDataModel implements DropDownTextFieldDataModel<T> { @Override public List<T> getMatchingData(String searchText) { List<?> l = data; int startIndex = Collections.binarySearch(l, (Object) searchText, comparator); int endIndex = Collections.binarySearch(l, (Object) (searchText + END_CHAR), comparator); if (startIndex < 0) { startIndex = -startIndex - 1; } if (endIndex < 0) { endIndex = -endIndex - 1; } return data.subList(startIndex, endIndex); } DefaultDropDownSelectionDataModel(List<T> data,
			DataToStringConverter<T> searchConverter);  DefaultDropDownSelectionDataModel(List<T> data, DataToStringConverter<T> searchConverter,
			DataToStringConverter<T> descriptionConverter); static DefaultDropDownSelectionDataModel<String> getStringModel(List<String> strings); @Override List<T> getMatchingData(String searchText); @Override int getIndexOfFirstMatchingEntry(List<T> list, String text); @Override ListCellRenderer<T> getListRenderer(); @Override String getDescription(T value); @Override String getDisplayText(T value);  }### Answer:
@Test public void testGetMatchingData() { List<TestType> matchingData = model.getMatchingData("a"); assertEquals(1, matchingData.size()); assertEquals("abc", matchingData.get(0).getName()); matchingData = model.getMatchingData("bac"); assertEquals(2, matchingData.size()); assertEquals("bac", matchingData.get(0).getName()); assertEquals("bace", matchingData.get(1).getName()); }