How to catch the Runtime exceptions in the customized way.............

Hi,

In our application We need to catch the Runtime Exceptions. that are generated in the application.

i have an idea of making a base exception class which extends the exception

and in that class making a Handler method and catching all the exceptions within this handler and displaying the message to UI and Reporting to Log.

I need to have an other option which is more suitable than this.

[423 byte] By [Ajay_reddya] at [2007-10-3 10:58:43]
# 1

What do you mean? Just catch RuntimeException in your outer call method/loop and log the exception ... ?

Or do you mean just catching RuntimeExceptions caused by your app? Then do the same and inspect the exception stack trace in the catch clause. If it contains on of your classes (packages) log it, otherwise throw it further.

MartinHilperta at 2007-7-15 6:25:02 > top of Java-index,Developer Tools,Debugging and Profiling Tool APIs...