Package org.apache.cayenne
Interface Validating
-
- All Known Implementing Classes:
BaseDataObject
,CayenneDataObject
,HybridDataObject
public interface Validating
Defines a number of callback methods that allow an object to be validated before safe. Entity class can implement this interface and its methods will be called automatically.- Since:
- 3.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
validateForDelete(ValidationResult validationResult)
Performs property validation of the DELETED object, appending any validation failures to the provided validationResult object.void
validateForInsert(ValidationResult validationResult)
Performs property validation of the NEW object, appending any validation failures to the provided validationResult object.void
validateForUpdate(ValidationResult validationResult)
Performs property validation of the MODIFIED object, appending any validation failures to the provided validationResult object.
-
-
-
Method Detail
-
validateForInsert
void validateForInsert(ValidationResult validationResult)
Performs property validation of the NEW object, appending any validation failures to the provided validationResult object. This method is invoked by ObjectContext before committing a NEW object to the database.
-
validateForUpdate
void validateForUpdate(ValidationResult validationResult)
Performs property validation of the MODIFIED object, appending any validation failures to the provided validationResult object. This method is invoked by ObjectContext before committing a MODIFIED object to the database.
-
validateForDelete
void validateForDelete(ValidationResult validationResult)
Performs property validation of the DELETED object, appending any validation failures to the provided validationResult object. This method is invoked by ObjectContext before committing a DELETED object to the database.
-
-