简体   繁体   English

SceneBuilder Kit瘫痪了Gluon魅力隐藏的依赖?

[英]SceneBuilder Kit crippled by Gluon charm hidden dependency?

Downloaded Gluon Scene Builder Kit. 下载胶子场景生成器套件。 Upon execution the program will crash during "EditController" creation - instancing. 在执行时,程序将在“EditController”创建期间崩溃 - 实例化。

Tried older versions and scoured the net to no avail. 尝试旧版本并搜索网络无济于事。 The range of options are (to me) limited as there are hidden dependencies is closed libs. 选项范围(对我来说)有限,因为隐藏的依赖关系是封闭的库。

public class Main extends Application { @Override public void start(Stage primaryStage) throws Exception { EditorController editor_controller = new EditorController(); 公共类Main扩展Application {@Override public void start(Stage primaryStage)throws Exception { EditorController editor_controller = new EditorController(); ... ... } public static void main(String[] args){ launch(args); ......} public static void main(String [] args){launch(args); } } }}

I expected to see at the least the content pane but instead got: 我希望至少能看到内容窗格,但却得到了:

"java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at javafx.graphics/com.sun.javafx.application.LauncherImpl.lau java的java.base / jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)中的java.base / jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(本机方法)中的java.lang.reflect.InvocationTargetException。 base / jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)at java.base / java.lang.reflect.Method.invoke(Method.java:566)at javafx.graphics/com.sun.javafx。 application.LauncherImpl.lau

... ...

Caused by: java.lang.ClassNotFoundException: com.gluonhq.charm.glisten.control.AppBar at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521) ... 13 more" 引起:java.lang.ClassNotFoundException:com.gluonhq.charm.glisten.control.AppBar,位于java.base / jdk.internal的java.base / jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)。 loader.ClassLoaders $ AppClassLoader.loadClass(ClassLoaders.java:178)at java.base / java.lang.ClassLoader.loadClass(ClassLoader.java:521)... 13 more“

Solved the issue by adding "charm-glisten-5.0.2.jar" to the project references (I'm using IntelliJ btw). 通过在项目引用中添加“charm-glisten-5.0.2.jar”解决了这个问题(我正在使用IntelliJ btw)。 Which Jar is NOT referenced anywhere on - in the SceneBuilder kit download download section, or the site. 在SceneBuilder工具包下载下载部分或网站上的任何地方都没有引用哪个Jar。

So, if one wishes to expose scene builder in YOUR app, NOT simply to integrate it into your IDE, then make sure you add the above jar as a reference to your project. 因此,如果有人希望在您的应用程序中公开场景构建器,而不是简单地将其集成到您的IDE中,那么请确保添加上面的jar作为项目的参考。 It can be found in the repo at https://nexus.gluonhq.com/nexus/content/repositories/releases/com/gluonhq/charm-glisten/5.02/ 它可以在https://nexus.gluonhq.com/nexus/content/repositories/releases/com/gluonhq/charm-glisten/5.02/的回购中找到

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM