Basic Project Setup

Basic Project Setup

I'll use Apache Maven 2.x and IntelliJ IDEA as my primary development tools, so you might want to learn how to use these first if you plan to work through the examples for yourself. All source code and project files for this walkthrough is available from github using

git://github.com/ansgarkonermann/bean-validation-with-jsr303.git

as clone URL.

Hibernate Validator is the reference implementation (RI) of JSR 303, and to be able to use it, we of course need to include the appropriate Maven dependencies into our project's pom. Luckily, the correct <dependency> section for Maven is listed on the JSR 303 RI's download page.

The Maven/IDEA project structure you'll find in the repository given above uses a parent/child pom structure, and since we're going to need the Hibernate Validator dependency for each of the child projects, I included them in the parent pom.

Project Structure