private void update(@NotNull Component component, @NotNull ToIntFunction<? super JTree> rowFunc) {
    if (component instanceof JTree tree) {
      int rowNew = rowFunc.applyAsInt(tree);
      int rowOld = rowHolder.getAndSet(rowNew);
      if (rowNew != rowOld) onHover(tree, rowNew);
    }
  }
private void update(@NotNull Component component, @NotNull ToIntFunction<? super JTree> rowFunc)