org.apache.derby.impl.sql.execute
Class UniqueIndexSortObserver
java.lang.Object
org.apache.derby.impl.sql.execute.BasicSortObserver
org.apache.derby.impl.sql.execute.UniqueIndexSortObserver
- All Implemented Interfaces:
- SortObserver
class UniqueIndexSortObserver
- extends BasicSortObserver
Unique index aggregator. Enforces uniqueness when
creating a unique index or constraint.
|
Constructor Summary |
UniqueIndexSortObserver(boolean doClone,
boolean isConstraint,
java.lang.String indexOrConstraintName,
ExecRow execRow,
boolean reuseWrappers,
java.lang.String tableName)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
isConstraint
private boolean isConstraint
indexOrConstraintName
private java.lang.String indexOrConstraintName
tableName
private java.lang.String tableName
UniqueIndexSortObserver
public UniqueIndexSortObserver(boolean doClone,
boolean isConstraint,
java.lang.String indexOrConstraintName,
ExecRow execRow,
boolean reuseWrappers,
java.lang.String tableName)
insertDuplicateKey
public DataValueDescriptor[] insertDuplicateKey(DataValueDescriptor[] in,
DataValueDescriptor[] dup)
throws StandardException
- Description copied from class:
BasicSortObserver
- Called prior to inserting a duplicate sort
key.
- Specified by:
insertDuplicateKey in interface SortObserver- Overrides:
insertDuplicateKey in class BasicSortObserver
- Parameters:
in - the current row that the sorter
is on the verge of retaining. It is a duplicate
of existingRow.dup - the row that is already in the
the sorter which is a duplicate of insertRow
- Returns:
- the row to be inserted by the sorter. If null,
then nothing is inserted by the sorter. Distinct
sorts will want to return null.
- Throws:
StandardException - Thrown on failure- See Also:
AggregateSortObserver.insertDuplicateKey(org.apache.derby.iapi.types.DataValueDescriptor[], org.apache.derby.iapi.types.DataValueDescriptor[])
Apache Derby V10.10 Internals - Copyright © 2004,2013 The Apache Software Foundation. All Rights Reserved.