Package com.exedio.cope
Class IntegrityViolationException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.exedio.cope.ConstraintViolationException
-
- com.exedio.cope.IntegrityViolationException
-
- All Implemented Interfaces:
Serializable
public final class IntegrityViolationException extends ConstraintViolationException
Signals, that an attempt to delete an item has been failed, because some other item point to that item with someitem field
.Also knows as foreign key constraint violation.
This exception is thrown by
Item.deleteCopeItem()
.- Author:
- Ralf Wiebicke
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description ItemField<?>
getAttribute()
Deprecated.Renamed togetFeature()
.ItemField<?>
getFeature()
Returns the item field, for which the integrity (foreign key) constraint has been violated.String
getMessage(boolean withFeature)
-
Methods inherited from class com.exedio.cope.ConstraintViolationException
getItem, getItemID, getItemPhrase, getItemText, getMessage, getMessageWithoutFeature
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Method Detail
-
getFeature
public ItemField<?> getFeature()
Returns the item field, for which the integrity (foreign key) constraint has been violated. Returns null, if the violated constraint is unknown.- Specified by:
getFeature
in classConstraintViolationException
-
getMessage
public String getMessage(boolean withFeature)
- Specified by:
getMessage
in classConstraintViolationException
-
getAttribute
@Deprecated public ItemField<?> getAttribute()
Deprecated.Renamed togetFeature()
.
-
-