private void check(PsiJavaCodeReferenceElement implementsElement,
                       PsiClass implementedClass,
                       PsiJavaCodeReferenceElement[] implementsElements) {
      for (PsiJavaCodeReferenceElement testImplementElement : implementsElements) {
        if (testImplementElement.equals(implementsElement) || !(testImplementElement.resolve() instanceof PsiClass testImplementedClass)) {
          continue;
        }
        if (testImplementedClass.isInheritor(implementedClass, true)) {
          registerError(implementsElement);
          return;
        }
      }
    }
private void check(PsiJavaCodeReferenceElement implementsElement,
                       PsiClass implementedClass,
                       PsiJavaCodeReferenceElement[] implementsElements)