boolean () { final ClassResolveResult resolveResult = resolveGenerics(); PsiClass aClass = resolveResult.getElement(); if (aClass == null) return false; for (PsiTypeParameter parameter : PsiUtil.typeParametersIterable(aClass)) { PsiType type = resolveResult.getSubstitutor().substitute(parameter); if (type != null) { if (!(type instanceof PsiWildcardType)) { return true; } final PsiType bound = ((PsiWildcardType)type).getBound(); if (bound != null) { if (((PsiWildcardType)type).isExtends()) { final PsiClass superClass = parameter.getSuperClass(); if (superClass != null && PsiUtil.resolveClassInType(bound) == superClass) { continue; } } return true; } } } return false; }