File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes What jars need to be delivered Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "What jars need to be delivered" Watch "What jars need to be delivered" New topic
Author

What jars need to be delivered

Piotr Nowicki
Ranch Hand

Joined: Jul 13, 2010
Posts: 610

I am reading my assignment (the part about deliverables) and it says that
(...)each part (client and server) must be executable using a command of this exact form: java-jar [](...)The mode flag must be either "server", indicating the server program must run, "alone", indicating standalone mode, or left out entirely, in which case the network client and gui must run.(...)This must be called runme.jar


I understood it as the single jar - runme.jar, which can be run in three ways:
- run only server part (networking mode),
- run only client part (networking mode),
- run server + client (non-networking mode).

In Andrew's Monkhouse book I read:
(...)Your project submission must consists of these components:
- An executable JAR file, which will run both the stand-alone client and the network-connected client,
- An executable server-specific JAR file, which will run the networked sever,
- A common JAR file which will contain code common to both client and server applications(...)


Which sounds like you've got to have 3 jar's, but the most important - two different jar's for running networking-mode application and non-networking one.

Is it up to us to decide how many JAR's we'll create? Or maybe Andrew's means that there should be one main runme.jar file which uses the other two jars (but then again - shouldn't these be "non-executable")?

Thanks in advance for replies.

Cheers!


OCP Java SE 6 Programmer, OCM Java SE 6 Developer, OCE Java EE 6 JSPSD, OCE Java EE 6 EJBD, OCE Java EE 6 JPAD, Spring 3.0 Core Professional.
Roel De Nijs
Bartender

Joined: Jul 19, 2004
Posts: 5300
    
  13

You can find the answer here. An Ant build script which builds your submission jar according to the instructions, with only a runme.jar (no other jars).


SCJA, SCJP (1.4 | 5.0 | 6.0), SCJD
http://www.javaroe.be/
Robert Benson
Ranch Hand

Joined: Apr 04, 2010
Posts: 56
Hi Pedro,

I did it the same way as you understand: one runme.jar that can be run in one of 3 ways.

However, my instructions specifically asked for the assigment to be packaged as two jar files. A jar file within a jar file. And it went on to state how the directories should be in the submission jar file.

I created my submission jar file which was something like scdja-SRxxxxxxx.jar (where SRxxxxxxx is your prometrics id). This jar contained the runme.jar as well as other directories and documents specified in the instructions.

Robert.


SCJP 6 , OCMJD 6 ,
http://www.robertbenson.ie/
Piotr Nowicki
Ranch Hand

Joined: Jul 13, 2010
Posts: 610

Thanks guys!
 
GeeCON Prague 2014
 
subject: What jars need to be delivered