public abstract class StandardIntegrityFix extends Object implements IntegrityFix
These correspond to the SQL ON DELETE CASCADE, ON DELETE SET NULL and ON DELETE NO ACTION.
| Modifier and Type | Class and Description |
|---|---|
static class |
StandardIntegrityFix.NameUnrecognisedException
Thrown when an invalid
StandardIntegrityFix is specified,
by a typing mistake in the DSD for example. |
| Modifier and Type | Field and Description |
|---|---|
static StandardIntegrityFix |
clear
Clear (make null) field in referring object.
|
static StandardIntegrityFix |
delete
Delete referred objects.
|
static StandardIntegrityFix |
prevent
Disallow the deletion.
|
| Modifier and Type | Method and Description |
|---|---|
static int |
count() |
static StandardIntegrityFix |
forIndex(int i)
Get a fix by its index.
|
Integer |
getIndex() |
String |
getName()
Integrity fixes are set in the DSD by name.
|
static StandardIntegrityFix |
named(String name)
Find by name.
|
abstract Enumeration<Persistent> |
referencesTo(Persistent referee,
Column column,
Enumeration refs,
Map referenceFixOfColumn)
Each
StandardIntegrityFix differs from another by the
way they implement {#referencesTo}. |
String |
toString()
Return the name and index.
|
public static final StandardIntegrityFix delete
public static final StandardIntegrityFix clear
public static final StandardIntegrityFix prevent
public String getName()
IntegrityFixgetName in interface IntegrityFixpublic Integer getIndex()
public abstract Enumeration<Persistent> referencesTo(Persistent referee, Column column, Enumeration refs, Map referenceFixOfColumn)
StandardIntegrityFix differs from another by the
way they implement {#referencesTo}.
delete deletes all references to this Persistent. referencesTo in interface IntegrityFixreferee - the Persistent we are deletingcolumn - the Column of the reference to Persistent
we are deleting, used in clearrefs - an Enumeration of the objects which contain
a reference to the Persistent we are deleting,
each is deleted, cleared or returned respectivelyreferenceFixOfColumn - a Map keyed on Column
giving the associated IntegrityFix, passed in to
the Persistent referer to delete itselfEnumeration of the remaining referers, which if
not empty will prevent deletionPersistent.delete(Map)public static StandardIntegrityFix forIndex(int i)
i - the indexpublic static int count()
public static StandardIntegrityFix named(String name)
name - the namepublic String toString()
toString in class ObjectObject.toString()Copyright © 2000–2021 PanEris. All rights reserved.