Newsflash

Publishing your articles and thoughts online was never so easy, Career discussions is looking for writers to contribute to our online content.
 

Login Form






Lost Password?
No account yet? Register

Syndicate


Home
TQAD - Java Exceptions Print E-mail
Written by Asif   
Friday, 09 March 2007

What are Checked and Unchecked exceptions in java?

In todays Tech question of the day we deal with the basic question of Exception handling in Java.


 

  Java defines two kinds of exceptions:

·         Checked exceptions: Exceptions that inherit from the Exception class are checked exceptions. Client code has to handle the checked exceptions thrown by the API, either in a catch clause or by forwarding it outward with the throws clause.

·         Unchecked exceptions: RuntimeException also extends from Exception. However, all of the exceptions that inherit from RuntimeException get special treatment. There is no requirement for the client code to deal with them, and hence they are called unchecked exceptions.

  

Exception
Exception

 

 

Last Updated ( Wednesday, 14 March 2007 )
 
< Prev   Next >
© 2010 Careerdiscussions.com
All content Copyright (C) @ CareerDiscussions.com and its authors, reproduction without prior consent prohibited