November 2017
Intermediate to advanced
420 pages
10h 29m
English
In the previous section, we had a quick look at the built-in validation constraints offered by the Bean Validation framework. There may be cases where you may want to build your own validation constraints. The Bean Validation framework supports that as well.
The core contracts that you should implement for a custom validation constraint are as follows:
Let's build a custom validation constraint for checking whether a department with the same name already exists for a given location. This constraint ...