boolean (String fqName, PsiJavaFile file) { final String shortName = ClassUtil.extractClassName(fqName); final PsiClass[] classes = file.getClasses(); for (PsiClass aClass : classes) { if (shortName.equals(aClass.getName()) && !fqName.equals(aClass.getQualifiedName())) { return true; } } return false; }