Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Checked to Unchecked Exception

 
Xon Bhuyan
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I read somewhere like :
"If a checked exception doesn�t make sense to you do not hesitate to convert it into unchecked exception ....."

How do you convert a checked exception, say IOException into unchecked Exception ?
 
Srinivasa Raghavan
Ranch Hand
Posts: 1228
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess that line was ment for custom exception classes.
To create a unchecked exception a class should inherit RuntimeException.
 
Stefan Willi
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


Stefan
 
Xon Bhuyan
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Stefan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic