Page 1 of 1

About Question com.enthuware.ets.scbcd.v5.2.91 : Question 30 test 4

Posted: Sun Jul 03, 2011 3:56 am
by Alex
Hi,
I think the version field must not be public, nor static or final. It can only be private, "package" or protected.
But in the answer you explain that it can have any acces modifier (so considering that public is permitted)

Do I mistake ?
Best regards,
Alex

Re: About Question com.enthuware.ets.scbcd.v5.2.91 : Question 30 test 4

Posted: Mon Jul 04, 2011 7:53 am
by admin
Hi,
No restriction on access modifier is mentioned in 9.1.17 Version Annotation or anywhere else in the specification. The explanation does note that it cannot be static or final.

HTH,
Paul.

Re: About Question com.enthuware.ets.scbcd.v5.2.91 : Question 30 test 4

Posted: Mon Jul 04, 2011 10:28 am
by Alex
Hi Paul, thanks for your answer.
I agree with your explanation.
But in 2.1 page 18 it is mentioned about instance variables of Entity that they must be protected, private or "default". So should we considerate that this paragraph exclude version instance variables ?
Regards,
Alex

Re: About Question com.enthuware.ets.scbcd.v5.2.91 : Question 30 test 4

Posted: Mon Jul 04, 2011 12:21 pm
by admin
You are right. Section 2.1 indeed says that. This should apply to @Version field as well. This has been fixed.

thanks for your feedback!