> I can not use TestData without an import even it is in
> the default package.
OK, let me be clearer. Consider the following trivial code:
---------------------------------
nopackage.java:
//package inpackage;
public class nopackage
{
public String s;
public nopackage(String s)
{
this.s = s;
}
}
packagetest.java:
package inpackage;
public class packagetest
{
static public void main(String[] args)
{
nopackage np = new nopackage(args[0]);
System.out.println(np.s);
}
}
---------------------------------
Try compiling without the package statement. Then uncomment the package
statement. See the problem? Because the test program is in a package, it
cannot access the packageless class.
The same is true of compiled JSP pages. Because Tomcat puts them in a
package, org.apache.jsp, they cannot access classes that aren't in a
package.
--- Noel
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>