orbiter 18 years ago
parent 3bafd643c0
commit d03cd41266

@ -240,7 +240,14 @@ public class kelondroFlexTable extends kelondroFlexWidthArray implements kelondr
}
public Object next() {
kelondroRow.Entry idxEntry = (kelondroRow.Entry) indexIterator.next();
kelondroRow.Entry idxEntry = null;
while ((indexIterator.hasNext()) && (idxEntry == null)) {
idxEntry = (kelondroRow.Entry) indexIterator.next();
}
if (idxEntry == null) {
serverLog.logSevere("kelondroFlexTable.rowIterator: " + tablename, "indexIterator returned null");
return null;
}
int idx = (int) idxEntry.getColLong(1);
try {
return get(idx);

@ -36,9 +36,11 @@ public class kelondroFlexWidthArray implements kelondroArray {
protected kelondroFixedWidthArray[] col;
protected kelondroRow rowdef;
protected String tablename;
public kelondroFlexWidthArray(File path, String tablename, kelondroRow rowdef) throws IOException {
this.rowdef = rowdef;
this.tablename = tablename;
// initialize columns
col = new kelondroFixedWidthArray[rowdef.columns()];

Loading…
Cancel
Save