@Override
  public boolean hasConfiguredAnnotationRoot(@NotNull PsiModifierListOwner owner) {
    VirtualFile file = PsiUtilCore.getVirtualFile(owner);
    if (file == null) {
      return false;
    }
    final List<OrderEntry> entries = 
     ProjectRootManager.getInstance(owner.getProject())
       .getFileIndex()
       .getOrderEntriesForFile(file);

    return ContainerUtil.exists(entries, entry -> entry instanceof LibraryOrSdkOrderEntry &&
                                                  ContainerUtil.filter(AnnotationOrderRootType.getFiles(entry),
                                                                       VirtualFile::isInLocalFileSystem).size() == 1);
 }
@Override
  public boolean hasConfiguredAnnotationRoot(@NotNull PsiModifierListOwner owner)