mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
find field: check accessors if they belong to same field
IDEA-190721; IDEA-130620
This commit is contained in:
@@ -184,6 +184,7 @@ public class JavaFindUsagesHandler extends FindUsagesHandler{
|
||||
ContainerUtil.iterate(containingClass.getMethods()));
|
||||
if (setter != null) accessors.add(setter);
|
||||
accessors.addAll(PropertyUtilBase.getAccessors(containingClass, fieldName));
|
||||
accessors.removeIf(accessor -> field != PropertyUtilBase.findPropertyFieldByMember(accessor));
|
||||
if (!accessors.isEmpty()) {
|
||||
boolean containsPhysical = ContainerUtil.find(accessors, psiMethod -> psiMethod.isPhysical()) != null;
|
||||
final boolean doSearch = !containsPhysical || askShouldSearchAccessors(fieldName);
|
||||
|
||||
Reference in New Issue
Block a user