Personal opinion, If there is a problem, but also hope that the great God to correct
1. Non-check exception is called Run-time exception, all inherited from RuntimeException exception is Non-check exception, if you do not handle will have virtual machine Main method handle
2. Exceptions that do not inherit from RuntimeException are check exceptions (such as IO Exceptions)
3. The upper caller must handle the check Exception: Try_catch or continue throws to the upper layer
4. Why check exceptions: typically, checking for exceptions is not a problem with your program writing, which is an exception that was previously caused by external factors: such as disk full, no write Permission. Obviously these are not the reasons for your Program.
But you can not avoid these situations, in the event of these situations, you do not handle, continue to execute your program, may be wrong. All for better coding or to try to avoid errors, Java provides check exceptions,
This means that the program forces you to handle these possible situations to avoid the next program error ...
So I personally understand that checking for exceptions is more like checking than exceptions. Just as
If (does not meet the criteria 1)
Return 0;
else if (not eligible 2)
Return 1;
Else check through, continue execution
But returning 0, 1 is clearly not an intuitive representation of the Problem. And There's no way to force you to deal with this Situation. All occurrences of a check exception, by throws an exception, which upper layer must be processed, either processed, or continued to the higher layer. anyway, someone has to deal with it.
Java check exceptions and Non-check exceptions