Versions
ExtVal release numbers are directly linked to the JSF version they're compatible with.
- ExtVal 1.1.x is compatible with JSF 1.1.x
- ExtVal 1.2.x is compatible with JSF 1.2.x
- ExtVal 2.0.x is compatible with JSF 2.0.x
Setup
Required steps:
- Download the required ExtVal jar-files. (As an alternative, you can of course checkout the Source Code and build ExtVal yourself.) Basically you just have to choose the validation module(s) you would like to use and include it/them as well as the core of ExtVal in your JSF application. See the Module Documentation section to find more info on which modules you may need in your project. Currently you need at least:
myfaces-extval-core-*.jar
- Optional: The validation module you would like to use (e.g.:
myfaces-extval-property-validation-*.jar
and/or myfaces-extval-bean-validation-*.jar
and/or your own implementation) - Optional: Furthermore, you might need a component support module for the component library you are using. Or you might need the generic component support module. E.g. ICEfaces as well as RichFaces use some special tricks. Therefore, you need the generic component support module. However, there are also component libs which don't need an additional support module. Esp. with JSF 2 you should test if you really need a component support module. If something renders differently, you just have to include the generic component support module.
- Add the ExtVal jar-files to your classpath.
- Use the annotations.
That's it!
Hello MyFaces ExtVal
The Getting Started page shows some basic examples. Further information is available in some of the External Documentation.
Custom Constraints
This example shows the implementation of custom ExtVal constraint.
Customize ExtVal