Sunday, January 28, 2007

the difference between ‘throw’ and ‘throws’ ?And it’s application?

Exceptions that are thrown by java runtime systems can be handled by Try and catch blocks. With throw exception we can handle the exceptions thrown by the program itself. If a method is capable of causing an exception that it does not
handle, it must specify this behavior so the callers of the method can guard
against that exception.

SOURCE : www.referjava.com

No comments: