ExecRow row,
TupleDescriptor parentTupleDescriptor,
DataDictionary dd )
throws StandardException
{
SubCheckConstraintDescriptor checkDesc = null;
if (SanityManager.DEBUG)
{
SanityManager.ASSERT(
row.nColumns() == SYSCHECKS_COLUMN_COUNT,
"Wrong number of columns for a SYSCHECKS row");
}
DataValueDescriptor col;
DataDescriptorGenerator ddg;
ReferencedColumns referencedColumns;
String constraintText;
String constraintUUIDString;
UUID constraintUUID;
ddg = dd.getDataDescriptorGenerator();
/* 1st column is CONSTRAINTID (UUID - char(36)) */
col = row.getColumn(SYSCHECKS_CONSTRAINTID);
constraintUUIDString = col.getString();
constraintUUID = getUUIDFactory().recreateUUID(constraintUUIDString);
/* 2nd column is CHECKDEFINITION */
col = row.getColumn(SYSCHECKS_CHECKDEFINITION);
constraintText = col.getString();
/* 3rd column is REFERENCEDCOLUMNS */
col = row.getColumn(SYSCHECKS_REFERENCEDCOLUMNS);
referencedColumns =
(ReferencedColumns) col.getObject();
/* now build and return the descriptor */
checkDesc = new SubCheckConstraintDescriptor(
constraintUUID,
constraintText,
referencedColumns);
return checkDesc;
}