|
SPT Object Database API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.lang.Throwable
java.lang.Exception
com.sptci.prevayler.PrevalentException
com.sptci.prevayler.ConstraintException
public class ConstraintException
An exception used to indicate that a constraint violations has been encountered while persisting the prevalent object.
© Copyright 2008 Sans Pareil Technologies, Inc.
| Field Summary | |
|---|---|
private static String |
FIELD_PATTERN
The pattern for displaying constraint violation. |
private static String |
OID_PATTERN
The pattern used to generate the message for a oid violation. |
private static long |
serialVersionUID
|
| Constructor Summary | |
|---|---|
protected |
ConstraintException()
Default constructor. |
|
ConstraintException(PrevalentObject object)
Create a new instance of the exception using OID_PATTERN to
display the message for the unique object id constraint being violated. |
|
ConstraintException(PrevalentObject object,
String fields)
Create a new instance of the exception using FIELD_PATTERN to
display the message for unique constraint on specified fields being
violated. |
|
ConstraintException(String message)
Create a new instance of the exception with the specified message. |
| Method Summary |
|---|
| Methods inherited from class java.lang.Throwable |
|---|
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private static final long serialVersionUID
private static final String FIELD_PATTERN
private static final String OID_PATTERN
| Constructor Detail |
|---|
protected ConstraintException()
public ConstraintException(String message)
message - The message to associate with the exception.
public ConstraintException(PrevalentObject object,
String fields)
FIELD_PATTERN to
display the message for unique constraint on specified fields being
violated.
object - The prevalent object for which the violation was raised.fields - A string representing the fields on which the constraint
was defined.public ConstraintException(PrevalentObject object)
OID_PATTERN to
display the message for the unique object id constraint being violated.
object - The prevalent object for which the violation was raised.
|
SPT Object Database API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||