About Question enthuware.jwpv6.2.1085 :

Moderator: admin

Post Reply
johnlong
Posts: 197
Joined: Mon Jun 20, 2016 5:06 pm
Contact:

About Question enthuware.jwpv6.2.1085 :

Post by johnlong »

This error page mapping will only be used if NoLicenseException is made to extend from RuntimeException.It is not the only way to get it working.
If it works, why answer is marked as wrong?

admin
Site Admin
Posts: 10034
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.jwpv6.2.1085 :

Post by admin »

Did you read the explanation?
The option says that it is the only way. The explanation says that it is not the only way.
If you like our products and services, please help us by posting your review here.

johnlong
Posts: 197
Joined: Mon Jun 20, 2016 5:06 pm
Contact:

Re: About Question enthuware.jwpv6.2.1085 :

Post by johnlong »

Yes, I understand, if it is NOT the only way, why not choose this way?

admin
Site Admin
Posts: 10034
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.jwpv6.2.1085 :

Post by admin »

The option claims that it is the only way. Is it the only way? No. So it is a wrong option.
If you like our products and services, please help us by posting your review here.

johnlong
Posts: 197
Joined: Mon Jun 20, 2016 5:06 pm
Contact:

Re: About Question enthuware.jwpv6.2.1085 :

Post by johnlong »

Yes, I see now, I missed that part of question. Thank you.

mart1jn
Posts: 1
Joined: Mon Jun 04, 2018 2:18 am
Contact:

Re: About Question enthuware.jwpv6.2.1085 :

Post by mart1jn »

sorry to bump this topic, but I have a follow-up question based on the original one. You're saying that the option ...
This error page mapping will only be used if NoLicenseException is made to extend from RuntimeException.
... is wrong due to the word "only". However the option marked as correct also has the word "only":
As such, this error page mapping will only be used if a servlet wraps this exception into a ServletException and then throws the ServletException.
To me the reasoning isn't consistent. But perhaps you could explain.

admin
Site Admin
Posts: 10034
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: About Question enthuware.jwpv6.2.1085 :

Post by admin »

The reasoning is valid in both the options. It is not always just the word "only" that makes an option right or wrong. You have to read the whole statement.
In this case, think of it this way - Can you show me any other way the given error page mapping can be used even if a servlet doesn't wrap this exception into a ServletException given that NoLicenseException extends Exception?

If no, then the option is correct i.e. the only way this mapping will be used is if a servlet throws the NoLicenseException after wrapping it into a ServletException.
If you like our products and services, please help us by posting your review here.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest