File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Checked Exceptions Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Checked Exceptions" Watch "Checked Exceptions" New topic
Author

Checked Exceptions

md ali
Greenhorn

Joined: Sep 06, 2001
Posts: 25
Hi All,
Can anyone please tell me that what is meant by the term checked exceptions. And what is meant by term unchecked exceptions.
Thanks & Reagrds
Muhammad Ali
Valentin Crettaz
Gold Digger
Sheriff

Joined: Aug 26, 2001
Posts: 7610
Unchecked Exceptions are all Exceptions that are subclassing RuntimeException, i.e. RuntimeException and all its subclasses.
Checked Exceptions are all subclasses of Exception except the RuntimeException branch of the hierarchy.
Val


SCJP 5, SCJD, SCBCD, SCWCD, SCDJWS, IBM XML
[Blog] [Blogroll] [My Reviews] My Linked In
Roopa Bagur
Ranch Hand

Joined: Nov 03, 2000
Posts: 267
Checked exception are subclasses of Exception & has to be handled in your code in a try catch block or should be thrown using throws clause else the compiler will complain. Whereas unchecked exceptions being subclass of RuntimeException need not have to be handled in your code. They will be thrown during runtime.
Hope this helps.
Originally posted by md ali:
Hi All,
Can anyone please tell me that what is meant by the term checked exceptions. And what is meant by term unchecked exceptions.
Thanks & Reagrds
Muhammad Ali

md ali
Greenhorn

Joined: Sep 06, 2001
Posts: 25
Thankyou for your prompt replies and help.
Regards
Muhammad Ali
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Checked Exceptions
 
Similar Threads
Exceptions
Questions from mock Exam !!!
Exceptions
checked & unchecked exceptions
checked and Unchecked exceptions