Tim Boudreau
|
Posted: November 26, 2009 17:59 by Tim Boudreau
|
|
One issue mentioned elsewhere was the desire to use the built-in Validators for non-fatal conditions (I think the only one that does not use Severity.FATAL is the URL validator that may tell you an internet host name is longer than some browsers handle). So now, if you want to, say, suggest to the user that a field not be left blank, but not require it not to be blank, you can do Validator<String> v = Validators.limitSeverity(Severity.WARNING,Validators.REQUIRE_NON_EMPTY_STRING); validationGroup.add(theTextField, v); and you'll get a warning message instead of a fatal message. |
Ability to downgrade Severity
Replies: 2 - Last Post: December 04, 2009 19:29
by: hugoheden
by: hugoheden
showing 1 - 3 of 3
hugoheden
|
Posted: December 04, 2009 19:29 by hugoheden
|
| Sounds very useful. Not sure about the name "limitSeverity".. In the future we may want to support "upgrading/increasing" severity as well (if we add built-in Validators that default to Severity.WARNING or info).. so how about "withSeverity", "changeSeverity", "overrideSeverity" or something like that? |
Replies: 2 - Last Post: December 04, 2009 19:29
by: hugoheden
by: hugoheden








