Complex validations and rules :

If the declaration validation rules does not meet our need, we can go to complex one. So we need to add custom code in the entity object impl file:

- Accessors : generate get and set methods for each attribute
- Validation method : this create a validationEntity() method so we can define validation across all attributes
- Create method: for initialization code; we can use it for setting the default values.
- Remove method: this will fire if the entity is marked as deleted from the entity object cache
- Data manipulation methods : can be used to override default entity object behavior, the behavior of insert or delete

Accessors Example
Validation Method Example
Create Method Example