April April 19, Custom tags provide a clean separation of responsibilities between the Web designers JSP-developers and the Java programmers. The Java programmers implement custom JSP tags. The Web designers select these tags declaratively to activate the Java implementation.
Custom Validation Attribute in MVC Application - Dot Net Tutorials
When you are implementing Struts based application you need to implement some code to validate the input incoming data. We can validate the input data by overriding validate method in FormBean class. We need to implement the validation logic inside the validate method. Lot of fields that we validate require same logic to validate them. To avoid this problem and to simplify the validation handling, Apache has introduced validation framework. Validation framework is not a part of struts frame work ,it should be integrated into the struts explicitly.
Struts 2 validation is configured via XML or annotations. Manual validation in the action is also possible, and may be combined with XML and annotation-driven validation. Validation also depends on both the validation and workflow interceptors both are included in the default interceptor stack. The validation interceptor does the validation itself and creates a list of field-specific errors. Annotations can be used as an alternative to XML for validation.