Am Montag, den 20.08.2007, 16:05 +0200 schrieb Philipp von
Weitershausen:
> This is exactly what I would suggest: The function should return a list 
> of validation errors. Similar semantics are used in zope.formlib's 
> validate() method. I agree with Wichert's objection about being a bit 
> confusing, though. Perhaps a better name than "validateSchema" could 
> solve this problem, though I can't think of a good one right now... 
> getValidationErrors() seems to naive...
> 
> Having access to the original ValidationError exceptions (incl. the 
> field name that they were thrown for) is probably all the information 
> you're ever going to want (and get).

Right. The validation error objects are probably enough as they have
enough context to retrieve the field or invariant for which they apply.

_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to