Nested try catch

Exception handlers can be nested within one another. It means try, catch or a finally block can in turn contains another set of try catch finally sequence. In such a scenario, when a particular catch or finally block is unable to handle an Exception, that exception will be rethrown automatically and such exception would be […]

Share this article on

Custom Exception

Custom exceptions are also called as user defined exceptions We know that, Java has already provided bunch of exceptions to handle various scenarios like ArithmeticException,NullPointerException,ArrayIndexOutOfBoundException etc. These exceptions will be thrown by java based on pre-defined conditions ArithmeticException will be thrown whenever we divide number by zero NullPointerException will be thrown whenever we access method […]

Share this article on
< Previous Next >