From: Ken K. <kk...@sn...> - 2002-06-02 23:19:22
|
> 1.) If field empty, return true as valid > 2.) If field not empty, validate using assigned validators > > If that is the case, then you would have to put that logic in the > validator (i.e. in a regular expression validator you would have to > account for empty values). Perhaps it would be useful to be able to tag > a field as optional? I think so. I don't want the converter to run on an empty field either. I also think it would be nice to have these ValidationResultMap methods: String getOriginalValue(name): Should only return null if name doesn't exist. Object getConvertedValue(name): Can return null. Object getConvertedOrOriginalValue(name): Return the original value if invalid--otherwise the converted one. String [] getGroupErrorMessages() String getErrorOrMessage(name): Return the message if valid--otherwise the error msg. Instead of having to deal with two ValidationResultMaps, it would be nice to have a wrapper object. Ken |