| java.lang.Object org.apache.derby.iapi.sql.dictionary.TupleDescriptor org.apache.derby.iapi.sql.dictionary.ConstraintDescriptor org.apache.derby.iapi.sql.dictionary.KeyConstraintDescriptor org.apache.derby.iapi.sql.dictionary.ForeignKeyConstraintDescriptor
Constructor Summary | |
protected | ForeignKeyConstraintDescriptor(DataDictionary dataDictionary, TableDescriptor table, String constraintName, boolean deferrable, boolean initiallyDeferred, int[] fkColumns, UUID constraintId, UUID indexId, SchemaDescriptor schemaDesc, ReferencedKeyConstraintDescriptor referencedConstraintDescriptor, boolean isEnabled, int raDeleteRule, int raUpdateRule) | | ForeignKeyConstraintDescriptor(DataDictionary dataDictionary, TableDescriptor table, String constraintName, boolean deferrable, boolean initiallyDeferred, int[] fkColumns, UUID constraintId, UUID indexId, SchemaDescriptor schemaDesc, UUID referencedConstraintId, boolean isEnabled, int raDeleteRule, int raUpdateRule) |
raDeleteRule | int raDeleteRule(Code) | | |
raUpdateRule | int raUpdateRule(Code) | | |
referencedConstraintDescriptor | ReferencedKeyConstraintDescriptor referencedConstraintDescriptor(Code) | | interface to this descriptor
- public ReferencedKeyConstraintDescriptor getReferencedConstraint()
throws StandardException;
- public UUID getReferencedConstraintId()
throws StandardException;
- public boolean isSelfReferencingFK()
throws StandardException;
|
referencedConstraintId | UUID referencedConstraintId(Code) | | |
ForeignKeyConstraintDescriptor | protected ForeignKeyConstraintDescriptor(DataDictionary dataDictionary, TableDescriptor table, String constraintName, boolean deferrable, boolean initiallyDeferred, int[] fkColumns, UUID constraintId, UUID indexId, SchemaDescriptor schemaDesc, ReferencedKeyConstraintDescriptor referencedConstraintDescriptor, boolean isEnabled, int raDeleteRule, int raUpdateRule)(Code) | | Constructor for a ForeignKeyConstraintDescriptor
Parameters: dataDictionary - The data dictionary that this descriptor lives in Parameters: table - The descriptor of the table the constraint is on Parameters: constraintName - The name of the constraint. Parameters: deferrable - If the constraint can be deferred. Parameters: initiallyDeferred - If the constraint starts life deferred. Parameters: fkColumns - columns in the foreign key Parameters: constraintId - UUID of constraint Parameters: indexId - The UUID for the backing index Parameters: schemaDesc - The SchemaDescriptor for the constraint Parameters: referencedConstraintDescriptor - is referenced constraint descriptor Parameters: isEnabled - is the constraint enabled? |
ForeignKeyConstraintDescriptor | ForeignKeyConstraintDescriptor(DataDictionary dataDictionary, TableDescriptor table, String constraintName, boolean deferrable, boolean initiallyDeferred, int[] fkColumns, UUID constraintId, UUID indexId, SchemaDescriptor schemaDesc, UUID referencedConstraintId, boolean isEnabled, int raDeleteRule, int raUpdateRule)(Code) | | Constructor for a ForeignKeyConstraintDescriptor
Parameters: dataDictionary - The data dictionary that this descriptor lives in Parameters: table - The descriptor of the table the constraint is on Parameters: constraintName - The name of the constraint. Parameters: deferrable - If the constraint can be deferred. Parameters: initiallyDeferred - If the constraint starts life deferred. Parameters: fkColumns - columns in the foreign key Parameters: constraintId - UUID of constraint Parameters: indexId - The UUID for the backing index Parameters: schemaDesc - The SchemaDescriptor for the constraint Parameters: referencedConstraintId - is referenced constraint id Parameters: isEnabled - is the constraint enabled? |
getConstraintType | public int getConstraintType()(Code) | | Gets an identifier telling what type of descriptor it is
(UNIQUE, PRIMARY KEY, FOREIGN KEY, CHECK).
An identifier telling what type of descriptor it is(UNIQUE, PRIMARY KEY, FOREIGN KEY, CHECK). |
getRaDeleteRule | public int getRaDeleteRule()(Code) | | Gets a referential action rule on a DELETE
referential rule defined by the user during foreign key creattionfor a delete (like CASCDE , RESTRICT ..etc) |
getRaUpdateRule | public int getRaUpdateRule()(Code) | | Gets a referential action rule on a UPDATE
referential rule defined by the user during foreign key creattionfor an UPDATE (like CASCDE , RESTRICT ..etc) |
getReferencedConstraintId | public UUID getReferencedConstraintId() throws StandardException(Code) | | Get the constraint id for the constraint that this FK references.
Will return either a primary key or a unique key constriant.
the constraint id exception: StandardException - on error |
isSelfReferencingFK | public boolean isSelfReferencingFK() throws StandardException(Code) | | Am I a self-referencing FK? True if my referenced
constraint is on the same table as me.
true/false exception: StandardException - on error |
needsToFire | public boolean needsToFire(int stmtType, int[] modifiedCols)(Code) | | Does this constraint need to fire on this type of
DML? True if insert or update and columns intersect
Parameters: stmtType - the type of DML (StatementType.INSERT|StatementType.UPDATE|StatementType.DELETE) Parameters: modifiedCols - the columns modified, or null for all true/false |
Fields inherited from org.apache.derby.iapi.sql.dictionary.KeyConstraintDescriptor | UUID indexId(Code)(Java Doc)
|
|
|