This is an example of how you can leverage Groovy to specify Hibernate validator constraints programmatically instead
of with annotations or raw xml, and apply different constraints at runtime.
Code is available for anyone to learn from and is originally authored by Kelly Robinson(kellyrob at gmail.com)