Announcement Announcement Module
No announcement yet.
Paged validation support? Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Paged validation support?

    I was wondering if Spring might perhaps better support "paged" validation as it arises from paged data entry controllers (eg. AbstractWizardFormController)... for example an interface like

    public interface PagedValidator extends Validator {
    	public static final int VALIDATE_ALL_PAGES = -1;
    	 * Validate an object for a specific "page" in a multi-page validation
    	 * workflow, where the object must be of a class for which
    	 * the supports() method returned true.
    	 * @param obj  Populated object to validate
    	 * @param errors  Errors object we're building. May contain
    	 * errors for this field relating to types.
    	 * @param page Page to validate. Pages should be 0-based, and if anything 
    	 * less than 0 then validation for all pages should be performed.
    	void validate(Object obj, Errors errors, int page);
    As such a controller would have a standardized way of handling paged validation as opposed to relying on vaildateXXX() methods as currently described in the MVC documentation.