liveBook · Manning

JavaBean Validation API

The JavaBean Validation API is a Java standard for declaring and evaluating constraints on object properties, data, and executable parameters.

How 2 Manning books explain it

Java Persistence with Spring Data and Hibernate epub

Bean Validation is a Java specification for declaring and evaluating constraints on object properties and method parameters.

How it is used
Centralizes domain integrity rules so presentation, business, persistence, and database-facing code can validate consistent data.
How deep it goes
Defines declarative constraints and demonstrates programmatic violation inspection, while deferring exhaustive constraint catalogs and implementation internals.
Examples
Uses Item, User, and Log entities with NotNull and Size constraints, plus a future auction-end date and Validator test.
What you can do after
Apply it via validation annotations and Validator APIs to detect invalid domain objects before persistence.

Read how Java Persistence with Spring Data and Hibernate epub explains JavaBean Validation API →

Spring in Action, Sixth Edition

The Java standard for declaring and evaluating constraints on Java object properties and method parameters, originally specified as JSR 303.

How it is used
Supports declarative validation of Spring MVC form data through constraints on domain objects and controller-triggered checks.
How deep it goes
Explains dependency setup, property annotations, controller integration, messages, and view errors, but defers regular-expression details.
Examples
Uses Taco and TacoOrder fields, delivery addresses, credit-card checks, expiration patterns, CVV digits, and ingredient counts.
What you can do after
Apply it via Spring MVC to declare constraints, trigger validation, and show submitted-form errors.

Read how Spring in Action, Sixth Edition explains JavaBean Validation API →

Related concepts

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.