GenericAttributeValue<PsiClass> () { final DomElement domElement = getExtensionPointClassNameElement(); if (domElement == null) return null; if (domElement instanceof With with) { return with.getImplements(); } // only With and GenericAttributeValue<PsiClass> can be returned @SuppressWarnings("unchecked") GenericAttributeValue<PsiClass> genericAttributeValue = (GenericAttributeValue<PsiClass>)domElement; return genericAttributeValue; }