我创建了一个 Java 项目来自动化 COMSOL Multiphysics 中的仿真。但是,每当我尝试运行代码时,都会遇到以下错误。
java.lang.UnsatisfiedLinkError: com.comsol.nativejni.server.FlRunnable.createRunInfo(Lcom/comsol/nativejni/CPointer;)V
at com.comsol.nativejni.server.FlRunnable.createRunInfo(Native Method)
at com.comsol.nativejni.server.FlRunnable.<init>(Unknown Source)
at com.comsol.nativeutil.runnable.f.<init>(Unknown Source)
at com.comsol.model.method.GeomSequenceMethod$1.<init>(Unknown Source)
at com.comsol.model.method.GeomSequenceMethod.<init>(Unknown Source)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.comsol.model.internal.impl.PrimitiveModelEntityImpl.a(Unknown Source)
at com.comsol.model.internal.impl.PrimitiveModelEntityImpl.bm(Unknown Source)
at com.comsol.model.internal.impl.GeomSequenceImpl.method(Unknown Source)
at com.comsol.model.internal.impl.GeomSequenceImpl.method(Unknown Source)
at com.comsol.model.internal.impl.ModelEntityImpl.c_(Unknown Source)
at com.comsol.model.internal.impl.ModelEntityImpl.tag(Unknown Source)
at com.comsol.model.internal.impl.GeomListImpl.doCreate(Unknown Source)
at com.comsol.model.internal.impl.GeomListImpl.a(Unknown Source)
at com.comsol.model.internal.impl.GeomListImpl$1.a(Unknown Source)
at com.comsol.model.internal.impl.GeomListImpl$1.execute(Unknown Source)
at com.comsol.model.clientserver.ClientManager$1.call(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Failed to find methods for: com.comsol.model.internal.impl.GeomSequenceImpl
看起来编译器正在寻找与我正在使用的方法关联的库,这很奇怪,因为我将它们添加到项目中。这是该项目的照片:
我觉得我错过了一些非常简单的东西,但我无法弄清楚。谢谢