|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.axiondb.constraints.BaseConstraint
public abstract class BaseConstraint
Abstract base Constraint implementation.
| Constructor Summary | |
|---|---|
BaseConstraint(java.lang.String name,
java.lang.String type)
Creates a Constraint with the
given name and type. |
|
| Method Summary | |
|---|---|
abstract boolean |
evaluate(RowEvent event)
Evaluate the given event under me. |
java.lang.String |
getName()
Get my name. |
java.lang.String |
getType()
Get a human-readable descrption of the type of constraint I represent. |
boolean |
isDeferrable()
Return whether or not I am deferrable. |
boolean |
isDeferred()
Return whether or not I am deferred. |
void |
resolve(Database db,
TableIdentifier table)
This base implementation is a no-op. |
void |
setDeferrable(boolean deferrable)
Set whether or not I am deferrable. |
void |
setDeferred(boolean deferred)
Set whether or not I am deferred. |
void |
setName(java.lang.String name)
Sets the name of this constraint. |
protected TableIdentifier[] |
toArray(TableIdentifier table)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.axiondb.Constraint |
|---|
evaluate, evaluate |
| Constructor Detail |
|---|
public BaseConstraint(java.lang.String name,
java.lang.String type)
Constraint with the
given name and type.
name - the name of this constraint (see setName(java.lang.String))
which may be nulltype - the type of this constraint (see getType()),
which should not be null| Method Detail |
|---|
public abstract boolean evaluate(RowEvent event)
throws AxionException
Constraintfalse if the
constraint I represent has been violated.
evaluate in interface ConstraintAxionException
public void resolve(Database db,
TableIdentifier table)
throws AxionException
resolve in interface ConstraintAxionExceptionpublic java.lang.String getName()
Constraint
getName in interface Constraintpublic void setName(java.lang.String name)
null a unique
name is programatically generated.
setName in interface Constraintpublic java.lang.String getType()
Constraint
getType in interface Constraintpublic boolean isDeferred()
Constraint
isDeferred in interface Constraint
public void setDeferred(boolean deferred)
throws AxionException
Constraintdeferrableand deferred is true.
setDeferred in interface ConstraintAxionExceptionpublic boolean isDeferrable()
Constraint
isDeferrable in interface Constraintpublic void setDeferrable(boolean deferrable)
Constraint
setDeferrable in interface Constraintprotected TableIdentifier[] toArray(TableIdentifier table)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||