This week's book giveaway is in the Cloud/Virtualizaton forum.
We're giving away four copies of Mesos in Action and have Roger Ignazio on-line!
See this thread for details.
Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

explain checked and unchecked exception

 
pandianjava
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please explain above topics
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Java Ranch has thousands of visitors every week, many with surprisingly similar names. To avoid confusion we have a naming convention, described at "JavaRanch Naming Policy" . We require names to have at least two words (not just letters), separated by a space, and strongly recommend that you use your full real name. We want to get to know you as a Professional. Please choose a new name which meets the requirements and re-register.

Cindy
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
PJ,

The simplest explanation is that checked exceptions are checked for by the compiler... the compiler makes sure that you either put something that will throw these exceptions inside a try...catch block, or that you make the method that contains them propegate the exception upwards. Unchecked exceptions require neither of these and so are not checked for by the compiler. All unchecked exceptions inherit from RuntimeException, so if you look at RuntimeException in the API, you can see a listing of all the "official" unchecked exceptions if you see what extends RuntimeException.

HTH,
-Nate

P.S. - Listen to Cindy and use your real name from now on, please!
 
manish paliwal
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
in simple words checked exception r that exception that r checked by compiler and unchecked exception is checked by runtime
------------------
manish paliwal(or just mann )
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic