• 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
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

Possible errata in OCP SE11 Study Guide by Jeanne Boyarsky and Scott Selikoff

 
Greenhorn
Posts: 9
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello!

I believe I have found an error in one of the review questions for Chapter 1. According to the answer to question #14, "The jar command allows the use of the classpath, making option C correct." However, when I type "jar --help" in the command prompt I do not get -cp as one of the available options. Also, I do not understand how -cp could be potentially useful for the jar command. I'm not a Java expert and would be grateful if someone could clear this up for me.  
 
Marshal
Posts: 80447
451
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Welcome to the Ranch

Thank you for giving the book's authors; that makes it much easier to identify the book. Please supply more details of the question for those of us who don't have that book.
What do you know about jars? Have you been through the Java™ Tutorials? Maybe the bit about classpath refers to the manifest file's contents.
 
author & internet detective
Posts: 42109
934
Eclipse IDE VI Editor Java
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Nikolai,
Welcome to CodeRanch!

Table 1.5 shows the options you need to know for the jar command.. -cp is not in that list.  (And as you note, it doesn't exist.)  When I wrote the question, i was thinking of the Jar manifest which allows a classpath. But that's not on the exam and it certianly isn't the -cp flag. I've logged this an errata and given you credit.

If you are curious what I was thinking of, here's a reference
 
Nikolai Vinoku
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you for the warm welcome, guys.
Thank you for the link, Jeanne. It never occurred to me that jar files could reference each other.
By the way, I also found a small typo in Table 2.2 Reserved words. Short begins with an uppercase S instead of lowercase. Not sure if such typos are worth mentioning, though.
 
Jeanne Boyarsky
author & internet detective
Posts: 42109
934
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
Everything is worth mentioning.  We maintain two lists. The public errata is everything that is actually wrong. (Short vs short is wrong). We also have a private list of things that aren't wrong but could be clearer. We kept track of *everything* people said about the Java 8 books and considered it when writing the Java 11 versions. It's like programming. You want to regression test so you don't the same errors!

This particular one is interesting. It was correct in the OCA 8 book. It was correct in our first draft and after our technical editor saw it. It was wrong in the next phase of rendering. So I think someone's Word was "helpful" and "corrected" it to something that was wrong.

In any case, thank you for pointing it out!
 
Nikolai Vinoku
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Jeanne, I found another typo.
It is in Chapter 2, section "Initializing variables". The paragraph beginning with "Believe it or not...".
The second sentence begins with "Java is not case sensitive...". Should be replaced with "Java is case sensitive...".
I'm using the Kindle edition, so, unfortunately, I can't point you to the exact page.
By the way, is it okay if I keep posting in this thread?
 
Campbell Ritchie
Marshal
Posts: 80447
451
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not something important, but I think it might be better to start a new thre‍ad for each error. Other people might have different opinions.
If that error about “not case sensitive” is on page 57, it has been noticed already.
 
Jeanne Boyarsky
author & internet detective
Posts: 42109
934
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
Yes, Ester noticed it a few days ago and we put it in the errata.

I'm ok with simple typos in either the same thread or a different one. Anything that might require discussion is easier in a separate thread though.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic