The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
April 2001

Advertisement

Advertisement

This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.

Message:

By compiling one application class the javac is compiling application class plus two more classes that are used by this application class, wy.

Posted by Burim Gosalci on May 13, 2001 at 9:06 PM

I am first year student at south bank university in london. i had an assignment to write a small propram that simulates softaware for creating key cards for key card locks. in writing this program i have writen three classes. two classes are used only to create objects while the third class is a class that has the main method and will use those two methods to instanciate the objects that are to be used. while testing the classes i heve realised that by compiling the class with the main method ather two clasess ser being compiled. how did i realise this. i made some changes to one of the class more precise i changed the value of the string variable called status from own to withdrawn and did not compile that class but compiled the class with the main method but wen run the class the variable status had the value withdrawn. all the classes wer in the same directory so i changed the variable status back to own and moved the source with extension java to ather directory and than compiled the class with the main method but this time the variable status was still withdrawn. does this mean that javac will check the date of the files if the class was resantky modified and if the source code has more resent date than the class file it will be compiled automatically.sory for my spelling mistakes.



Replies:

Sponsored Links



Google
  Web Artima.com   
Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us