Exemple #1
0
 /**
  * Enable or disable foreign key constraint checking for this table.
  *
  * @param session the session
  * @param enabled true if checking should be enabled
  * @param checkExisting true if existing rows must be checked during this call
  */
 public void setCheckForeignKeyConstraints(
     Session session, boolean enabled, boolean checkExisting) {
   if (enabled && checkExisting) {
     if (constraints != null) {
       for (Constraint c : constraints) {
         c.checkExistingData(session);
       }
     }
   }
   checkForeignKeyConstraints = enabled;
 }