Page 1 of 1
About Question enthuware.ocpjp.v8.2.1201 :
Posted: Fri Nov 06, 2015 9:37 am
by lveto15
Shouldn't in this question two options be selected?
Maybe I don't fully understand the question and the explanation, but after reading the explanation I would add to the answer also the third option (MyResource_fr_CA.properties adn MyResource_fr_CA.java will be the result).
Re: About Question enthuware.ocpjp.v8.2.1201 :
Posted: Fri Nov 06, 2015 8:09 pm
by admin
MyResource_fr_CA.java is not a class file. It is a Java file.
HTH,
Paul.
Re: About Question enthuware.ocpjp.v8.2.1201 :
Posted: Tue Apr 11, 2017 3:26 am
by nikitos
In Boyarsky and Selikoff attention is to the .java and .properties files. So looks intricately
Re: About Question enthuware.ocpjp.v8.2.1201 :
Posted: Tue Apr 11, 2017 4:26 am
by admin
I can't comment on what any book says but a .java file is not a valid resource bundle file. You can certainly create a resource bundle using java code in a .java file but in that case it will be compiled into a .class file and it is the .class file that is a valid resource bundle file. Not .java file. A java file will not be picked up by the JVM when you look for a resource bundle.
So you need to confirm with the book author about what they mean.
HTH,
Paul.
Re: About Question enthuware.ocpjp.v8.2.1201 :
Posted: Wed Sep 11, 2019 11:47 am
by henrid
Ìn the OCP Java SE 8 Programmer II Guide (Sierra/Bates), the same is presented, only talking about .properties and .java files being looked for. i never noticed, but I understand the JVM will be looking for .class files instead. Thanks to Enthuware!
Re: About Question enthuware.ocpjp.v8.2.1201 :
Posted: Tue Nov 05, 2019 6:32 pm
by bioshark.dev
I fully understand that the JVM reads from a .class file. I even stumbled upon this problem while I was doing exercises. I forgot to compile the resource bundle class
But still, as previously highlighted in this thread, 2 books (one from Oracle Press) are using the term .properties and .java files, so it builds patterns in the brain. It's an easy error to make on the exam, if the actual exam indeed disregards .java files from answers
Cheers.