public int idx = 0;
public Iterator(Builder<T> list) {
this.list = list;
}
public T next() {
<BUG>return list.factory.fromStructBuilder(list.builder.getStructElement(idx++));
}</BUG>
public boolean hasNext() {
return idx < list.size();
}

public int idx = 0;
public Iterator(Reader<T> list) {
this.list = list;
}
public T next() {
return list.reader.getStructElement(factory, idx++);
}
public boolean hasNext() {
return idx < list.size();
}
