medi.db.constraint
Class FKAuthor

java.lang.Object
  |
  +--javatools.db.DbConstraint
        |
        +--medi.db.constraint.FKAuthor

public class FKAuthor
extends DbConstraint

Represents the constraint for AUTHOR table.


Field Summary
 
Fields inherited from class javatools.db.DbConstraint
automaticChecking, canDoUpdate, CASCADE, cloned, constraintEmulation, constraints, currentOperation, defaultValues, DELETE_OPERATION, deleteCascadeChildren, deleteOperations, DO_NOTHING, fatherColsChildren, fatherRecords, fatherTables, fatherTablesColumns, fromList, INSERT_OPERATION, intoList, refColsChildren, refColumns, refs, searchSets, selector, SET_DEFAULT, SET_NULL, sonIndexes, sonsWhere, sonTables, table, UPDATE_CASCADE, UPDATE_OPERATION, updateCascadeChildren, updateFromLists, updateIntoLists, updateOperations, where
 
Constructor Summary
FKAuthor(DbAbstractTable tbl)
          Creates new FKAuthor.
 
Method Summary
 void check(int operation)
          Checks if the specified operation can be made.
 void setAuthorTelephoneNoTable(AuthorTelephoneNo tbl, int index)
          Sets AuthorTelephoneNo table.
 void setRealizedTable(Realized tbl, int index)
          Sets the Realized table to use.
 int update(int operation)
          Checks (if automatic checking is set) and updates, performing the operation.
 
Methods inherited from class javatools.db.DbConstraint
build, checkChildren, checkFathers, checkThis, clear, clone, getAutomaticChecking, getConstraintEmulation, getDefaultValues, getDeleteOperation, getFatherColumns, getFatherTable, getFatherTablesCount, getRefColumns, getSonFatherIndex, getSonTable, getSonTablesCount, getTable, getUpdateOperation, initLists, initStaticLists, setAutomaticChecking, setConstraintEmulation, setSelector, setValueLists, setWhere, updateThis
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FKAuthor

public FKAuthor(DbAbstractTable tbl)
Creates new FKAuthor.

Parameters:
tbl - The Author table to use.
Method Detail

setRealizedTable

public void setRealizedTable(Realized tbl,
                             int index)
Sets the Realized table to use.

Parameters:
tbl - The table to use.
index - How "Realized" references this table?

setAuthorTelephoneNoTable

public void setAuthorTelephoneNoTable(AuthorTelephoneNo tbl,
                                      int index)
Sets AuthorTelephoneNo table.

Parameters:
tbl - The table to use.
index - How "AuthorTelephoneNo" references this table?

check

public void check(int operation)
           throws DbException
Checks if the specified operation can be made.

Specified by:
check in class DbConstraint
Parameters:
operation - The operation to do.
Throws:
DbException - If something goes wrong.

update

public int update(int operation)
           throws DbException
Checks (if automatic checking is set) and updates, performing the operation.

Specified by:
update in class DbConstraint
Parameters:
operation - The operation to do.
Returns:
The result from the execute() method.
Throws:
DbException - If something goes wrong.