public class TdbIntegrityRule
extends java.lang.Object
Constructor and Description |
---|
TdbIntegrityRule()
Constructor, creates a blank rule
|
TdbIntegrityRule(TdbIntegrityRule src)
Copy constructor
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj)
Test a rule for equality with another.
|
java.lang.String |
getKey()
Retrieve the name of the field that holds the foreign key
|
java.lang.String |
getLinkDatabase()
Retrieve the name of the target database for the link
|
java.lang.String |
getLinkField()
Retrieve the name of the field in the target database that holds the
key for which this rule is a foreign reference.
|
TdbIntegrityType |
getOnDelete()
Retrieve the action to be taken in the current database if a record in
the target database is deleted.
|
TdbIntegrityType |
getOnUpdate()
Retrieve the action to be taken in the current database if a record in
the target database is updated.
|
boolean |
isOutgoing()
Check if this rule is outgoing (i.e.
|
void |
setKey(java.lang.String key)
Establish the name of the field that holds the foreign key
|
void |
setLinkDatabase(java.lang.String database)
Establish the name of the target database for the link
|
void |
setLinkField(java.lang.String field)
Establish the name of the field in the target database that holds the
key for which this rule is a foreign reference.
|
void |
setOnDelete(TdbIntegrityType action)
Establish the action to be taken in the current database if a record in
the target database is deleted.
|
void |
setOnUpdate(TdbIntegrityType action)
Establish the action to be taken in the current database if a record in
the target database is updated.
|
void |
setOutgoing(boolean mode)
Establish whether this rule is outgoing (i.e.
|
public TdbIntegrityRule()
public TdbIntegrityRule(TdbIntegrityRule src)
src
- Source from which to copypublic java.lang.String getKey()
public void setKey(java.lang.String key)
key
- Foreign key fieldpublic java.lang.String getLinkDatabase()
public void setLinkDatabase(java.lang.String database)
database
- Target database namepublic java.lang.String getLinkField()
public void setLinkField(java.lang.String field)
field
- Target field namepublic TdbIntegrityType getOnDelete()
public void setOnDelete(TdbIntegrityType action)
action
- The "on delete" actionpublic TdbIntegrityType getOnUpdate()
public void setOnUpdate(TdbIntegrityType action)
action
- The "on update" actionpublic boolean isOutgoing()
public void setOutgoing(boolean mode)
mode
- true if this database is the master in the foreign key relationshippublic boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- Object to test for equality