For this type of question,
where Exceptions/Errors are said to be thrown either:
1. by JVM
2. by Application (programmatically)
Would it be reasonable to see all checked Exceptions as being thrown programmatically?
About Question enthuware.ocajp.i.v7.2.1017 :
Moderator: admin
-
- Posts: 29
- Joined: Fri Aug 08, 2014 11:22 am
- Contact:
-
- Site Admin
- Posts: 10046
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.ocajp.i.v7.2.1017 :
Yes, it would be a reasonable memory aid. But just to be clear, the opposite is not true i.e. all unchecked exceptions are not necessarily thrown only by the JVM automatically.
If you like our products and services, please help us by posting your review here.
-
- Posts: 19
- Joined: Sat Mar 25, 2017 5:38 am
- Contact:
Re: About Question enthuware.ocajp.i.v7.2.1017 :
The illegalState exception and illegalArgument exceptions are not checked exceptions but the answer says these should be handled by the programmer. I thought programmer is required to handle checked exceptions.
-
- Site Admin
- Posts: 10046
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.ocajp.i.v7.2.1017 :
No, the answer doesn't say they these should be handled by the programmer. Please read the complete explanation carefully and let me know if something is not clear.
thank you,
Paul.
thank you,
Paul.
If you like our products and services, please help us by posting your review here.
Who is online
Users browsing this forum: Google [Bot] and 93 guests