Unchecked exceptions are subtypes of RuntimeException.
Subtypes of Error are also considered unchecked.
Everything else is checked.
Yes, you need to know this, and what exceptions are which, for the exam.
If you have K&B (or any other decent study book) that will contain a full description of the important excpetions, including which ones are thrown by the JVM and which ones programmatically (you need to know that too).
It's all in the K&B book. I made a simple class diagram detailing all this information for myself. You could do the same (me just giving it to you is not as much value as you doing it yourself).
You want Chapter 5, Objective 2.6. On page 386 (SCJP6) there is an excellent table that covers almost everything.
Have a look at the JAVA API, starting at java.lang.Throwable or java.lang.Exception. This will also help you understand the Exception Hierarchy more also, and differentiate between Checked and unchecked Exceptions.
be a well encapsulated person, don't expose your privates, unless you public void getWife()!
Hi guys,
I do understand the difference between checked and unchecked Exception.
But i don't understand the relation of checked/unchecked Exception with JVM and Programmatically thrown Exceptions.
Is it true that:
JVM Exception: Unchecked Exception(Runtime)
Programmatically thrown Exception : Checked/ Unchecked.
In K&B all the examples of Programmatically thrown Exception are Unchecked Exceptions. Does all of the checked Exception comes under Prog Thrown Exception??