void link(IndexRowIterator other) { other.next = next; next.last = other; other.last = this; next = other; }
/** * Constructor declaration * * @param name HsqlName of the index * @param table table of the index * @param column array of column indexes * @param type array of column types * @param unique is this a unique index * @param constraint does this index belonging to a constraint * @param forward is this an auto-index for an FK that refers to a table defined after this table * @param visColumns count of visible columns */ Index( Database database, HsqlName name, Table table, int[] column, int[] type, boolean isPk, boolean unique, boolean constraint, boolean forward, int[] pkcols, int[] pktypes, boolean temp) { indexName = name; colIndex = column; colType = type; pkCols = pkcols; pkTypes = pktypes; isUnique = unique; isConstraint = constraint; isForward = forward; useRowId = (!isUnique && pkCols.length == 0) || (colIndex.length == 0); colCheck = table.getNewColumnCheckList(); ArrayUtil.intIndexesToBooleanArray(colIndex, colCheck); updatableIterators = Index.emptyIterator; updatableIterators.next = updatableIterators.last = updatableIterators; collation = database.collation; isTemp = temp; onCommitPreserve = table.onCommitPreserve; }
public void release() { if (last != null) { last.next = next; } if (next != null) { next.last = last; } }