GenericScanController
, RowCountable
ScanControllerRowSource
, ScanManager
B2IForwardScan
, B2IMaxScan
, BTreeForwardScan
, BTreeMaxScan
, BTreeScan
, GenericScanController
, HeapCompressScan
, HeapScan
, MergeScan
, MergeScanRowSource
, Scan
, SortBufferRowSource
, SortBufferScan
, SortScan
public interface ScanController extends GenericScanController
Scans are opened from a TransactionController.
A ScanController can handle partial rows. Partial rows
are described in RowUtil.
A scan controller is opened with a FormatableBitSet that describes the
columns that need to be returned on a fetch call. This FormatableBitSet
need not include any columns referenced in the qualifers, start
and/or stop keys.
TransactionController.openScan(long, boolean, int, int, int, org.apache.derby.iapi.services.io.FormatableBitSet, org.apache.derby.iapi.types.DataValueDescriptor[], int, org.apache.derby.iapi.store.access.Qualifier[][], org.apache.derby.iapi.types.DataValueDescriptor[], int)
,
GenericScanController
,
RowCountable
,
RowUtil
Modifier and Type | Field | Description |
---|---|---|
static int |
GE |
GE is used to position a scan at values greater than or or equal to the
given key in the scan.
|
static int |
GT |
GT is used to position a scan at values greater than the given key.
|
static int |
NA |
NA - argument is unused in call.
|
Modifier and Type | Method | Description |
---|---|---|
boolean |
delete() |
Delete the row at the current position of the scan.
|
void |
didNotQualify() |
A call to allow client to indicate that current row does not qualify.
|
boolean |
doesCurrentPositionQualify() |
Returns true if the current position of the scan still qualifies
under the set of qualifiers passed to the openScan().
|
void |
fetch(DataValueDescriptor[] destRow) |
Fetch the (partial) row at the current position of the Scan.
|
void |
fetchLocation(RowLocation destRowLocation) |
Fetch the location of the current position in the scan.
|
boolean |
fetchNext(DataValueDescriptor[] destRow) |
Fetch the (partial) row at the next position of the Scan.
|
void |
fetchWithoutQualify(DataValueDescriptor[] destRow) |
The same as fetch, except that the qualifiers passed to the openScan()
will not be applied. destRow will contain the current row even if it
has been changed and no longer qualifies.
|
boolean |
isCurrentPositionDeleted() |
Returns true if the current position of the scan is at a
deleted row.
|
boolean |
isHeldAfterCommit() |
Return true is the scan has been closed after a commit, but was
opened with holdability and can be reopened using
positionAtRowLocation.
|
boolean |
next() |
Move to the next position in the scan.
|
boolean |
positionAtRowLocation(RowLocation rl) |
Positions the scan at row location and locks the row.
|
boolean |
replace(DataValueDescriptor[] row,
FormatableBitSet validColumns) |
Replace the (partial) row at the current position of the scan.
|
close, getScanInfo, isKeyed, isTableLocked, newRowLocationTemplate, reopenScan, reopenScanByRowLocation
getEstimatedRowCount, setEstimatedRowCount
static final int GE
TransactionController.openScan(long, boolean, int, int, int, org.apache.derby.iapi.services.io.FormatableBitSet, org.apache.derby.iapi.types.DataValueDescriptor[], int, org.apache.derby.iapi.store.access.Qualifier[][], org.apache.derby.iapi.types.DataValueDescriptor[], int)
,
Constant Field Valuesstatic final int GT
TransactionController.openScan(long, boolean, int, int, int, org.apache.derby.iapi.services.io.FormatableBitSet, org.apache.derby.iapi.types.DataValueDescriptor[], int, org.apache.derby.iapi.store.access.Qualifier[][], org.apache.derby.iapi.types.DataValueDescriptor[], int)
,
Constant Field Valuesstatic final int NA
TransactionController.openScan(long, boolean, int, int, int, org.apache.derby.iapi.services.io.FormatableBitSet, org.apache.derby.iapi.types.DataValueDescriptor[], int, org.apache.derby.iapi.store.access.Qualifier[][], org.apache.derby.iapi.types.DataValueDescriptor[], int)
,
Constant Field Valuesboolean delete() throws StandardException
StandardException
- Standard exception policy.void didNotQualify() throws StandardException
Indicates to the ScanController that the current row does not qualify for the scan. If the isolation level of the scan allows, this may result in the scan releasing the lock on this row.
Note that some scan implimentations may not support releasing locks on non-qualifying rows, or may delay releasing the lock until sometime later in the scan (ie. it may be necessary to keep the lock until either the scan is repositioned on the next row or page).
This call should only be made while the scan is positioned on a current valid row.
StandardException
- Standard exception policy.boolean doesCurrentPositionQualify() throws StandardException
StandardException
- Standard exception policy.boolean isHeldAfterCommit() throws StandardException
StandardException
- Standard exception policy.positionAtRowLocation(org.apache.derby.iapi.types.RowLocation)
void fetch(DataValueDescriptor[] destRow) throws StandardException
destRow
- The row into which the value of the current
position in the scan is to be stored.StandardException
- Standard exception policy.RowUtil
void fetchWithoutQualify(DataValueDescriptor[] destRow) throws StandardException
destRow
- The row into which the value of the current
position in the scan is to be stored.StandardException
- Standard exception policy.boolean fetchNext(DataValueDescriptor[] destRow) throws StandardException
destRow
- The destRow row into which the value
of the next position in the scan is to be stored.StandardException
- Standard exception policy.fetch(org.apache.derby.iapi.types.DataValueDescriptor[])
,
RowUtil
void fetchLocation(RowLocation destRowLocation) throws StandardException
StandardException
- Standard exception policy.boolean isCurrentPositionDeleted() throws StandardException
StandardException
- Standard exception policy.boolean next() throws StandardException
StandardException
- Standard exception policy.boolean positionAtRowLocation(RowLocation rl) throws StandardException
rl
- RowLocation for the new position for the scan. The
RowLocation submitted should be a RowLocation which has
previously been returned by this ScanController.StandardException
- Standard exception policy.boolean replace(DataValueDescriptor[] row, FormatableBitSet validColumns) throws StandardException
StandardException
- Standard exception policy.RowUtil
Apache Derby V10.14 Internals - Copyright © 2004,2018 The Apache Software Foundation. All Rights Reserved.