Without any "import" statements, I'm a little surprised it compiled
file2.java. Try adding
import file2;
to file1.java, and
import file3;
to file2.java. See if that helps.
-Andy
> -----Original Message-----
> From: ALPESH KOTHARI [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, September 02, 1999 4:03 AM
> To: [EMAIL PROTECTED]
> Cc: [EMAIL PROTECTED]
> Subject: compiling files
>
>
> Hello All,
>
> I am using JDK1.2 pre v2 on RH6.0. I am facing a typical problem.
> Consider the situation:
>
> file1.java
>
> class file1{
>
> public file1(){
>
> xx=new file2();
>
> }
> }
>
> file2.java
>
> class file2(){
>
> public file2(){
>
> yy=new file3();
>
> }
> }
>
> file3.java
>
> class file3(){
> public file3(){
>
>
> }
> }
>
> Now, when i compile the main I think all the 3 files should make their
> respective class files and do the required work. But instead class
> files of file1.java and file2.java are made and file3.java is not
> touched. I have to explicited compile file3.java first and then
> file1.java to see the effect of file3. Is the feature built in compiler
> like that or a bug?
>
> I have read in java books that we dont need to compile the program
> seperately.
>
> I would like to hear from you.
>
> Thanking All,
> WIth regards
> alpesh
>
> ===
> KOTHARI ALPESH D.
> STUDENT M. TECH.
> CEDT
> INDIAN INSTITUTE OF SCIENCE
> BANGALORE-560 012
> INDIA
> __________________________________________________
> Do You Yahoo!?
> Bid and sell for free at http://auctions.yahoo.com
>
>
> ----------------------------------------------------------------------
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact
> [EMAIL PROTECTED]
>
----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]