Hello,

I use JDE 2.1.6beta2 with NT Emacs 20.3.10 on Windows NT4 SP4 and  It seems
that the import wizard (that is the jde-wiz-find-and-import command)
cannot find the core Java classes when using JDK 1.2.
The jde.wizards.ImportWizard class gets the current user classpath setting
from the "java.class.path" system property. In JDK 1.2 the core Java
classes no longer are in classpath but in bootclasspath instead.
I have made changes to the jde.wizards.ImportWizard class to search for
core Java classes in JDK 1.2 using the new "sun.boot.class.path" system
property.
It seems that the import wizard returns as many occurences of a class found
as the same path occurs in classpath. I have fixed that too.

Here is my patch. The import wizard works great now for me with Java 2.

56a57,62
>
>     // For Java 2!
>     String classPath2 = System.getProperty("sun.boot.class.path");
>     if (classPath2 != null)
>       classPath += classPathSeparator + classPath2;
>     167c173,176
<    importList += " \"" +  testName + "\"";
---
>         // Avoid duplicates!
>         testName = " \"" +  testName + "\"";
>         if (importList.indexOf(testName) == -1)
>           importList += testName;

 I hope this will help.

Sincerely.

David

Reply via email to