@NotNull
  private static Type getType(@Nullable VirtualFile file) {
    if (file == null) return Type.FILE;
    if (file.getFileType() instanceof ArchiveFileType) return Type.ARCHIVE;
    if (file.isDirectory()) return Type.DIRECTORY;
    return Type.FILE;
  }
@NotNull
  private static Type getType(@Nullable VirtualFile file)