--- Erik Price <[EMAIL PROTECTED]> wrote: > > > Jerry Jalenak wrote: > > > Just curious - how do most of you return errors from your business > model? > > Do you simply return an integer value (-1, 0. 99?) and then interpret > it in > > the action?
Yuck. > >Or do you return a error string that maps to something in > > ApplicationResources? Any other techniques? I'm trying to find a > 'best > > practice' on how to do this.... > > Java has a really elegant mechanism for returning errors called > Exceptions.... Errors from the business layer should be reported as exceptions. The exception could carry a list of error messages or resource keys so that the next layer can display a message to the user. Or the next layer could interpret the exception into some error message, it's your choice. David > > > > Erik > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > __________________________________ Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software http://sitebuilder.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]