Extend @Validate annotation to accept optional key attribute for custom error 
messages
--------------------------------------------------------------------------------------

                 Key: STS-281
                 URL: http://mc4j.org/jira/browse/STS-281
             Project: Stripes
          Issue Type: Improvement
          Components: Validation
    Affects Versions: Release 1.4.1
            Reporter: Sebastian Wiemer
         Assigned To: Tim Fennell


How about to add a new attribute to the @Validate annotation named 'key' (or 
something similar).
The idea is to have the possibility to create other (localized) error messages 
than those provided by
the validation framework so far.

@Validate(on="calc",required=true,key="conversion.error.for.my.specific.value")
private Integer value;

The 'key' attribute is ment to be optional. Further checkings are not required 
i think, because there are very
rare situations when you need a custom error message on property validation 
during the binding stage.
So it's up to the developer to provide a proper formatted message string in the 
resource bundle.



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://mc4j.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development

Reply via email to