Providing full support for development Struts applications JBoss Developer Studio comes with a visual validation editor. To create a new validation file, right click any folder in Project Explorer and select File > New > Other... from the context menu and then JBoss Tools Web > Struts > Validation File.
The validation editor works with five modes: Formsets, Validators, Constants and standard Tree and Source that you can easily switch over using tabs at the bottom of the editor.
The Formsets mode shows forms and their elements on the left side and the dialogue for defining their validation rules on the right side.
The Constants mode let you set constant values for your validation rules.
The validation file can also be viewed in a Tree mode.
At any point you have full control over the source by switching to the Source mode. Any editing in this mode will immediately be available in other modes of the editor.
You can also open your own custom or Struts-standard validation-rules.xml file.
The Validators mode shows the validation rules for a selected validator. You can of course add your own rules.
Here are the validation rules shown in the Source mode.