boolean (final PsiType type, final String className) { if (type instanceof PsiClassType) { final PsiClass psiClass = ((PsiClassType)type).resolve(); return psiClass != null && className.equals(psiClass.getQualifiedName()); } return false; }