void (@NotNull PsiElement element) { if (element instanceof PsiMethod) { myMethods.add((PsiMethod)element); } else if (element instanceof PsiVariable) { myVariables.add((PsiVariable)element); } else { LOG.error("Unknown declaration: " + element); } }