void (PsiType selectedType) { SuggestedNameInfo nameInfo = myTypesToSuggestions.get(selectedType); if (nameInfo == null) { nameInfo = myGenerator.getSuggestedNameInfo(selectedType); myTypesToSuggestions.put(selectedType, nameInfo); } myNameField.setSuggestions(nameInfo.names); }