@Override
  public boolean hasNext() {
    obtainNext();
    if (!isCurrentIsValid) return false;
    boolean value = isCurrentPassesFilter();
    while (!value && delegate.hasNext()) {
      Dom next = delegate.next();
      setCurrent(next);
      value = isCurrentPassesFilter();
    }
    return value;
  }
@Override
  public boolean hasNext()