PPT Slide
Both of these traditional approaches boil down to a case of the programmer simply ignoring the real problem, which is:
When a run-time error occurs in a method,
- how can we stop the method without allowing it to do any damage?
- how can we take appropriate actions to handle the error without having the program simply blow up or do something else that’s bad?
It is not acceptable for programs to fail or to do “bad behavior”!
We require some mechanism to recover from
unexpected or abnormal run-time situations.
Exceptions: The Real Problem