public static boolean isArchive(@Nullable VirtualFile file) {
    if (file == null) return false;
    if (isArchiveFileSystem(file) && file.getParent() == null) return true;
    return !file.isDirectory() &&
           FileTypeManager.getInstance().getFileTypeByFileName(file.getNameSequence()) == ArchiveFileType.INSTANCE &&
           !isArchiveFileSystem(file.getParent());
  }
public static boolean isArchive(@Nullable VirtualFile file)