M
merrittr
I have a old JDK installed 1.1.8 purposly to compile a applet below:
C:\javapdf\>javac -verbose -classpath C:\jdk1.1.8\lib\classes
SampleReader.java
[parsed SampleReader.java in 194 ms]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\Viewer.class in 61
ms]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\Viewer
$ViewerTransactor.class
in 21 ms]
[loaded C:\jdk1.1.8\lib\classes\java\applet\Applet.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Panel.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Container.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Component.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Object.class in 21 ms]
[checking class SampleReader]
[loaded C:\jdk1.1.8\lib\classes\java\awt\image\ImageObserver.class in
0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\MenuContainer.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\Serializable.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat
\RenderingObserver.class in 0 m
s]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\ViewerCommand.class
in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Exception.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Throwable.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\String.class in 30 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Frame.class in 21 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Window.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\BorderLayout.class in 21 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\LayoutManager.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\LayoutManager2.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Label.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Color.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\event\WindowAdapter.class in
0 ms]
[checking class SampleReader. 1]
[loaded C:\jdk1.1.8\lib\classes\java\awt\event\WindowListener.class in
0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\util\EventListener.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\event\WindowEvent.class in 30
ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\System.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FileInputStream.class in 20
ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\InputStream.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FileDescriptor.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\File.class in 11 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FileNotFoundException.class in
10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\IOException.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\PrintStream.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FilterOutputStream.class in 11
ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\OutputStream.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Error.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\RuntimeException.class in 0
ms]
[wrote SampleReader.class]
[wrote SampleReader$1.class]
[done in 1328 ms]
G:\javapdf\>
as you can see it compiles fine
(into 2 classes??? SampleReader.class SampleReader$1.class)
at this point I note that it says in the verbose compile :
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\Viewer.class in 61
ms]
I then browse to a web page with this applet tag:
<html>
<body>
<applet code="SampleReader.class" width=900 height=140></applet>
</body>
</html>
where I get the following output from the java console:
(which seems to suggest it didn't compile the imported
com/adobe/acrobat/Viewer
Java(TM) Plug-in: Version 1.3.1_19
Using JRE version 1.3.1_19 Java HotSpot(TM) Client VM
User home directory = C:\Documents and Settings\rwm132
----------------------------------------------------
c: clear console window
f: finalize objects on finalization queue
g: garbage collect
h: display this help message
l: dump classloader list
m: print memory usage
q: hide console
s: dump system properties
t: dump thread list
x: clear classloader cache
0-5: set trace level to <n>
----------------------------------------------------
java.lang.NoClassDefFoundError: com/adobe/acrobat/Viewer
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at sun.applet.AppletClassLoader.findClass(Unknown Source)
at sun.plugin.security.PluginClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.applet.AppletClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.applet.AppletClassLoader.loadCode(Unknown Source)
at sun.applet.AppletPanel.createApplet(Unknown Source)
at sun.plugin.AppletViewer.createApplet(Unknown Source)
at sun.applet.AppletPanel.runLoader(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
any ideas on how I can get this to work????
C:\javapdf\>javac -verbose -classpath C:\jdk1.1.8\lib\classes
SampleReader.java
[parsed SampleReader.java in 194 ms]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\Viewer.class in 61
ms]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\Viewer
$ViewerTransactor.class
in 21 ms]
[loaded C:\jdk1.1.8\lib\classes\java\applet\Applet.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Panel.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Container.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Component.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Object.class in 21 ms]
[checking class SampleReader]
[loaded C:\jdk1.1.8\lib\classes\java\awt\image\ImageObserver.class in
0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\MenuContainer.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\Serializable.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat
\RenderingObserver.class in 0 m
s]
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\ViewerCommand.class
in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Exception.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Throwable.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\String.class in 30 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Frame.class in 21 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Window.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\BorderLayout.class in 21 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\LayoutManager.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\LayoutManager2.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Label.class in 20 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\Color.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\event\WindowAdapter.class in
0 ms]
[checking class SampleReader. 1]
[loaded C:\jdk1.1.8\lib\classes\java\awt\event\WindowListener.class in
0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\util\EventListener.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\awt\event\WindowEvent.class in 30
ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\System.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FileInputStream.class in 20
ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\InputStream.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FileDescriptor.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\File.class in 11 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FileNotFoundException.class in
10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\IOException.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\PrintStream.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\FilterOutputStream.class in 11
ms]
[loaded C:\jdk1.1.8\lib\classes\java\io\OutputStream.class in 10 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\Error.class in 0 ms]
[loaded C:\jdk1.1.8\lib\classes\java\lang\RuntimeException.class in 0
ms]
[wrote SampleReader.class]
[wrote SampleReader$1.class]
[done in 1328 ms]
G:\javapdf\>
as you can see it compiles fine
(into 2 classes??? SampleReader.class SampleReader$1.class)
at this point I note that it says in the verbose compile :
[loaded C:\jdk1.1.8\lib\classes\com\adobe\acrobat\Viewer.class in 61
ms]
I then browse to a web page with this applet tag:
<html>
<body>
<applet code="SampleReader.class" width=900 height=140></applet>
</body>
</html>
where I get the following output from the java console:
(which seems to suggest it didn't compile the imported
com/adobe/acrobat/Viewer
Java(TM) Plug-in: Version 1.3.1_19
Using JRE version 1.3.1_19 Java HotSpot(TM) Client VM
User home directory = C:\Documents and Settings\rwm132
----------------------------------------------------
c: clear console window
f: finalize objects on finalization queue
g: garbage collect
h: display this help message
l: dump classloader list
m: print memory usage
q: hide console
s: dump system properties
t: dump thread list
x: clear classloader cache
0-5: set trace level to <n>
----------------------------------------------------
java.lang.NoClassDefFoundError: com/adobe/acrobat/Viewer
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at sun.applet.AppletClassLoader.findClass(Unknown Source)
at sun.plugin.security.PluginClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.applet.AppletClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.applet.AppletClassLoader.loadCode(Unknown Source)
at sun.applet.AppletPanel.createApplet(Unknown Source)
at sun.plugin.AppletViewer.createApplet(Unknown Source)
at sun.applet.AppletPanel.runLoader(Unknown Source)
at sun.applet.AppletPanel.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
any ideas on how I can get this to work????