@Override
	public List<Register> getMatchingData(String searchText) {

		if (searchText == null || searchText.length() == 0) {
			return registers;
		}

		searchText = searchText.toLowerCase();

		List<Register> regList = new ArrayList<>();
		for (Register reg : registers) {
			String regName = reg.getName().toLowerCase();
			if (regName.startsWith(searchText)) {
				regList.add(reg);
			}
		}
		return regList;
	}
The data model for {@link DropDownSelectionTextField} that allows the text field to work with
{@link Register}s.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/function/editor/RegisterDropDownSelectionDataModel.java