File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes classpath problem. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "classpath problem." Watch "classpath problem." New topic
Author

classpath problem.

sharma ishu
Ranch Hand

Joined: Sep 10, 2012
Posts: 70
Given the following directory structure:

test-|

|-GetJar.java

-myApp-|

|-Foo.java

And given the contents of GetJar.java and Foo.java:

public class GetJar{
public static void main(String[] args){
System.out.println(myApp.Foo.d);
}
}

package myApp;
public Foo{ public static int d=8;}

The cirrent directory is "test", and myApp/Foo.class is placed in aJAR file called MyJar.jar located in test.

How did the following invocation work?

java GetJar

This is question number 11 from chapter 10 of book "SCJP 6 by Kethy and Bates".
Please answer my question.
gurpeet singh
Ranch Hand

Joined: Apr 04, 2012
Posts: 924
    
    1

please refer this link http://www.coderanch.com/t/591259/java-programmer-SCJP/certification/Doubts-Chapter-fron-Kathy-Seira
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: classpath problem.