In the Java doc API : ocs\api\java\time\LocalDate.html
LocalDate shows no constructor,
so does LOcalDate use super Object class constructor ? how does that work ?
Hope someone find my question interesting.
Thanks.
How do I reset the email notification request back to 'YES' on this thread ?
I inadvertently click on the email link to turn off email notification on this thread.
So, you are say: IndexOutOfBoundsException which is subclass of java.lang.RuntimeException CANNOT be caught or thrown ?
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
java.lang.IndexOutOfBoundsException
Definition of "checked" exception: subclass of Exception but not subclass of RuntimeException.
"checked" exception must be caught or thrown to be compiled; while "unchecked" exception has option to be caught or thrown for successful compilation.
"unchecked" has option to be caught or thrown just like "checked" exception and if caught or throw will work just like "checked" exception.
Thank you for your reply and if this is not right, please reply.
I'm more confused than was before.
The following code will compile. But it calls Boolean kh = Array.getBoolean(value, 5) which has this method signature:
[/color]
which make me think, caller must catch or throw !!! otherwise it should not compile
The called Java method can throws any type of exception, and the calling method must catch it or throw it.
I read somewhere that Java has 2 types of exception: "checked" and "unchecked" and that "checked" must be subclass of Exception but not subclass of "RuntimeException".
This was the reason for my original post.
Now, I think the the "checked" exception is referring to the JDK methods that has "throws" clause.