tapestry-user@jakarta.apache.org
[Top] [All Lists]

Re: Custom Exception Hierarchy and Custom Exception Page

Subject: Re: Custom Exception Hierarchy and Custom Exception Page
From: "matthew c. mead"
Date: Fri, 18 Mar 2005 21:03:26 -0500
Kent Tong wrote:

matthew c. mead <m-apache <at> goof.com> writes:

The main issue I was wondering about was whether the approach had to be "wrap the exception in a RuntimeException." It sounds like it is.

No, it isn't. A better way is to let your exception classes extend RuntimeException.

Good point. Why is it better, though? Less object creation? The problem I have with my framework exceptions extending RuntimeException is that by doing so I can end up being sloppy about properly handling errors. If I'm forced to declare them thrown and catch them I can ensure consistency in error handling throughout the business layer of the application.



-matt


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: tapestry-user-help@xxxxxxxxxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>