无法从w3c加载java类 [英] Unable to load java class from w3c

查看:186
本文介绍了无法从w3c加载java类的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用ELKI进行OPTICS聚类( http://elki.dbs.ifi。 lmu.de/ )。

I am trying to do OPTICS-clustering with ELKI (http://elki.dbs.ifi.lmu.de/).

我尝试用提供的gui运行聚类,但后来我得到了这个例外:

I try do run the clustering with the provided gui, but then I get this exception:

Error in starting visualizer window.
java.lang.NoClassDefFoundError: org/w3c/dom/svg/SVGSVGElement
    at de.lmu.ifi.dbs.elki.visualization.gui.ResultWindow.<init>(Unknown Source)
    at de.lmu.ifi.dbs.elki.visualization.gui.ResultVisualizer$1.run(Unknown Source)
    at [...]
Caused by: java.lang.ClassNotFoundException: org.w3c.dom.svg.SVGSVGElement
    at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:323)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
    at de.lmu.ifi.dbs.elki.visualization.gui.ResultWindow.<init>(Unknown Source)
    at de.lmu.ifi.dbs.elki.visualization.gui.ResultVisualizer$1.run(Unknown Source)
    at [...]

我是unzi将w3c.jar导入 / usr / share / java 并进入程序的路径。但它仍然给我同样的错误。

I unzipped w3c.jar into /usr/share/java and into the path of the program. But it still gives me the same error.

我有一个很旧的Ubuntu(10.04),OpenJDK版本IcedTea6 1.13.3。但我猜这不是造成麻烦的,对吗?

I have quite an old Ubuntu (10.04) with OpenJDK version IcedTea6 1.13.3. But I guess that is not was is causing the trouble, right?

怎么办?

推荐答案

我认为你仍然需要将这个jar添加到classPath然后它会被识别。我不确定你在netbeans中使用什么ide,例如右键单击项目>库>添加jar / library。然后你的classLoader应该抱怨。

I think you still have to add that jar into classPath and then it will be recognized.Im not sure what ide you use bud in netbeans for instance rightclick project>libraries>add jar/library.Then your classLoader shoudnt be complaining.

这篇关于无法从w3c加载java类的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆