Home > Guides > Plugin Developers Guide > Bean Validation Plugin

Setup

In order to use the Bean Validation plugin, you first need to add the JAR file to the WEB-INF/lib directory of your application or include the dependency in your project's Maven POM file.

pom.xml

Where X.X.X is the current version of Struts 2. Please remember that the Bean Validation Plugin is available from version 2.5.

Configuration

 

struts.xml

Bean Validation Example

 

com.example.actions.BeanValidationAction