Win a copy of Rust Web Development this week in the Other Languages forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Jesse Silverman
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Frits Walraven

Sybex 1Z0-815, Mock test 2, question ID tb584704.JaSE11PrgISG.be2.19

 
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Jeanne and Scott,

This is regard to the book OCP Oracle Certified Professional Java SE 11 Programmer I Study Guide: Exam 1Z0-815.

I think that this question is wrong. All A, B, D, and E should be correct options.

Question: Which are true of the --module option? (Choose all that apply.)

Choices:
A. It is an option on the javac command.
B. It is an option on the java command.
C. It is an option on the jar command.
D. It is an option on the jdeps command.
E. It has a short form of -m.
F. It has a short form of -p.

The exam states that the correct choices are: B and E

But I chose A, B, D, E and got A, D wrong. The flag --module exists in both javac and jdeps.

My java version: java -version: openjdk version "11.0.7" 2020-04-14
javac --module: --module <module-name>, -m <module-name>---Compile only the specified module, check timestamps
jdeps --module: -m <module-name> --module <module-name>---Specify the root module for analysis
 
Marshal
Posts: 74642
335
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I couldn't find a --module option for the java tool. I did find it for jdeps. I presume you know where to find the errata and you have checked them.
 
Dimitri Nguyen
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Campbell Ritchie wrote:I couldn't find a --module option for the java tool. I did find it for jdeps. I presume you know where to find the errata and you have checked them.



Hi Ritchie, you can find this phrase in the link that you have posted.

Executes the main class in a module specified by mainclass if it is given, or, if it is not given, the value in the module. In other words, mainclass can be used when it is not specified by the module, or to override the value when it is specified.



But it is true that it's not an obvious command if we use the flag.

I didn't see this question on the errata. That's why I am reporting now. Cheers!
 
Campbell Ritchie
Marshal
Posts: 74642
335
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Dimitri Nguyen wrote:. . . Hi Ritchie, you can find this phrase . . .

Have found it now. Well done finding that
 
author & internet detective
Posts: 40913
840
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Confirmed and added to the errata. While these options aren't on the exam for these commands, they do exist!
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic