[1938] in java-interest

home help back first fref pref prev next nref lref last post

Re: Importing Classes into Applications

daemon@ATHENA.MIT.EDU (Bruce Raggett)
Wed Sep 20 09:29:52 1995

Date: Wed, 20 Sep 1995 22:50:42 +1200
To: java-interest@java.sun.com
From: brucer@chch.planet.org.nz (Bruce Raggett)

>Package declarations are mapped to directories, so the compiler is
>looking for "./crawford/prata_project/Stock.*"
(when you specify import crawford.prata_project.Stock.*;)
>not "./Stock.*".

I found the above explanation most helpful. However, on my Win95 machine
with the CLASSPATH environment variable set to .;C:\ javac found my package
when my default directory was C:\ but not when my default directory was not C:\
I assume that the C:\ in the CLASSPATH environment variable is not working.

Also I have another question. The documentation states that a package may
only contain one public class or one public interface. If this is correct,
and a package maps to a directory, do I have to store each public class and
each public interface in a separate directory?

Many thanks,
Bruce Raggett.

-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com

home help back first fref pref prev next nref lref last post