public @NotNull Iterator<T> iterate(T start, boolean fwd, boolean wrap) {
    if (!wrap || start == null) return iterate(start, fwd);
    return new JBIterator<>() {
      boolean wrapped = false;
      Iterator<T> it = iterate(start, fwd);

      @Override
      protected T nextImpl() {
        if (it.hasNext()) return it.next();
        if (wrapped) return stop();
        wrapped = true;
        it = from(iterate(null, fwd)).takeWhile(item -> item != start);
        return it.hasNext() ? it.next() : stop();
      }
    };
  }
public @NotNull Iterator<T> iterate(T start, boolean fwd, boolean wrap)