| Sign In/My Account | View Cart |
| Article: |
An Exception Handling Framework for J2EE Applications | |
| Subject: | useful ideas | |
| Date: | 2006-02-12 18:29:58 | |
| From: | Shrik | |
|
Response to: useful ideas
|
||
| Here is a catch. Please note that we are not throwing BaseAppException from the methods but its derived classes. In other words we are not throwing just java.lang.Exception but its so many derived classes. Definitely the throws clause just contains BaseAppException but client (ExceptionHandler) will get derived exception classes only, based on the principle of polymorphism. You need to see it from a perspective why do you use a base class in a method signature instead of its derived concrete classes in case you want to use polymorphism. You'll find an answer now on why we just throw BaseAppException. | ||
Showing messages 1 through 2 of 2.