@Override public CursorBuilder newCursor() { return wrapped.newCursor(); }
/** * Creates a normal, un-indexed cursor for the given table. * @param table the table over which this cursor will traverse */ public static Cursor createCursor(Table table) throws IOException { return table.newCursor().toCursor(); }
/** * Creates an indexed cursor for the given table. * <p> * Note, index based table traversal may not include all rows, as certain * types of indexes do not include all entries (namely, some indexes ignore * null entries, see {@link Index#shouldIgnoreNulls}). * * @param index index for the table which will define traversal order as * well as enhance certain lookups */ public static IndexCursor createCursor(Index index) throws IOException { return index.getTable().newCursor().setIndex(index).toIndexCursor(); }
private Iterator<Row> getComplexValFkIter( int complexValueFk, Collection<String> columnNames) throws IOException { if(_complexValIdCursor == null) { _complexValIdCursor = _flatTable.newCursor() .setIndexByColumns(_complexValFkCol) .toIndexCursor(); } return _complexValIdCursor.newEntryIterable(complexValueFk) .setColumnNames(columnNames).iterator(); }
public Cursor getCursor() throws IOException { Index idx = getBestIndex(); Cursor cursor; CursorBuilder cb = table.newCursor(); if (idx == null) { cursor = cb.toCursor(); } else { cursor = cb.setIndex(idx).toCursor(); } cursor.setColumnMatcher(new ColumnMatcher()); return cursor; }
/** * Creates an indexed cursor for the given table, narrowed to the given * range. * <p> * Note, index based table traversal may not include all rows, as certain * types of indexes do not include all entries (namely, some indexes ignore * null entries, see {@link Index#shouldIgnoreNulls}). * * @param index index for the table which will define traversal order as * well as enhance certain lookups * @param startRow the first row of data for the cursor (inclusive), or * {@code null} for the first entry * @param endRow the last row of data for the cursor (inclusive), or * {@code null} for the last entry */ public static IndexCursor createCursor(Index index, Object[] startRow, Object[] endRow) throws IOException { return index.getTable().newCursor().setIndex(index) .setStartRow(startRow) .setEndRow(endRow) .toIndexCursor(); }
throws IOException return index.getTable().newCursor().setIndex(index) .setStartRow(startRow) .setStartRowInclusive(startInclusive)