since recently I think we are forced to use IcedTea to run applets in Ubuntu 11.10. At least I don't see how to install Sun Java from the Software Center.
最近我认为我们不得不在Ubuntu 11.10中使用IcedTea来运行applet。至少我不知道如何从软件中心安装Sun Java。
I would like to debug an applet which gives problems in IcedTea. However, I don't know how to show the applet console. So no chance to see any Exceptions.
我想调试一个在IcedTea中出现问题的applet。但是,我不知道如何显示applet控制台。所以没有机会看到任何例外。
Cheers, Ruth
欢呼,露丝
4 个解决方案
#1
2
You can easily see near realtime the output of the IcedTea Java plugin by first running in two separate terminal windows the following commands then invoking the applet in your web browser.
通过在两个独立的终端窗口中运行以下命令,然后在web浏览器中调用applet,您可以很容易地实时看到IcedTea Java插件的输出。
$ watch -n 1 'cat $HOME/.icedteaplugin/java.stdout'
or
或
$ watch -n 1 'cat $HOME/.icedteaplugin/java.stderr'
java.stdout contains standard output of the running applet whereas java.stderr will capture standard error output (capture exceptions trace here).
java。stdout包含正在运行的applet的标准输出,而java则包含。stderr将捕获标准错误输出(在这里捕获异常跟踪)。
Note : the "-n" option flag lets you specify the refresh rate in seconds.
注意:“-n”选项标志允许您以秒为单位指定刷新速度。
#2
1
On Ubuntu 12.04, the location of the log files seems to have changed to ~/.icedtea/log
(~ meaning your home directory.)
在Ubuntu 12.04上,日志文件的位置似乎已经更改为~/。icedtea/log(~表示您的主目录)。
Alternatively to Tellurant's solution, you can open the log files ~/.icedtea/log/java.stderr
and ~/.icedtea/log/java.stdout
in gedit and click on reload every time something changes. The dot in front of icedtea makes the .icedtea directory a hidden directory. Hit CTRL-H in nautilus to see hidden directories.
作为Tellurant解决方案的另一种选择,您可以打开日志文件~/.icedtea/log/java。stderr和~ / .icedtea /日志/ java。在gedit中输入stdout,每次发生更改时单击reload。icedtea前面的点使.icedtea目录成为一个隐藏目录。按下nautilus的CTRL-H,查看隐藏的目录。
#3
1
In place of watch, tail -f or less , then press +f (follow) can be used.
代替手表,尾部-f或以下,然后按+f (follow)即可。
#4
0
In case you do want to install Oracle Java (Sun was bought by Oracle), here is a good guide:
如果您确实想安装Oracle Java (Sun被Oracle收购),这里有一个很好的指南:
http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html
http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html
Here are the command line commands:
以下是命令行命令:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
#1
2
You can easily see near realtime the output of the IcedTea Java plugin by first running in two separate terminal windows the following commands then invoking the applet in your web browser.
通过在两个独立的终端窗口中运行以下命令,然后在web浏览器中调用applet,您可以很容易地实时看到IcedTea Java插件的输出。
$ watch -n 1 'cat $HOME/.icedteaplugin/java.stdout'
or
或
$ watch -n 1 'cat $HOME/.icedteaplugin/java.stderr'
java.stdout contains standard output of the running applet whereas java.stderr will capture standard error output (capture exceptions trace here).
java。stdout包含正在运行的applet的标准输出,而java则包含。stderr将捕获标准错误输出(在这里捕获异常跟踪)。
Note : the "-n" option flag lets you specify the refresh rate in seconds.
注意:“-n”选项标志允许您以秒为单位指定刷新速度。
#2
1
On Ubuntu 12.04, the location of the log files seems to have changed to ~/.icedtea/log
(~ meaning your home directory.)
在Ubuntu 12.04上,日志文件的位置似乎已经更改为~/。icedtea/log(~表示您的主目录)。
Alternatively to Tellurant's solution, you can open the log files ~/.icedtea/log/java.stderr
and ~/.icedtea/log/java.stdout
in gedit and click on reload every time something changes. The dot in front of icedtea makes the .icedtea directory a hidden directory. Hit CTRL-H in nautilus to see hidden directories.
作为Tellurant解决方案的另一种选择,您可以打开日志文件~/.icedtea/log/java。stderr和~ / .icedtea /日志/ java。在gedit中输入stdout,每次发生更改时单击reload。icedtea前面的点使.icedtea目录成为一个隐藏目录。按下nautilus的CTRL-H,查看隐藏的目录。
#3
1
In place of watch, tail -f or less , then press +f (follow) can be used.
代替手表,尾部-f或以下,然后按+f (follow)即可。
#4
0
In case you do want to install Oracle Java (Sun was bought by Oracle), here is a good guide:
如果您确实想安装Oracle Java (Sun被Oracle收购),这里有一个很好的指南:
http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html
http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html
Here are the command line commands:
以下是命令行命令:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer