将Matlab嵌入到了RCP的一个view中,但是RCP与Matlab的连接总是报错,不管是将matlab提供的jar做成插件还是以第三方jar的形式引入RCP中都无法成功连接。跪求高手解决!以下是错误信息
??? Java exception occurred:
matlabcontrol.MatlabConnectionException: Connection to Java application could not be established
at matlabcontrol.MatlabConnector.connectFromMatlab(MatlabConnector.java:88)
Caused by: java.rmi.UnmarshalException: error unmarshalling return; nested exception is:
java.net.MalformedURLException: no protocol: Documents/eclipse/MatlabControl/
at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
at matlabcontrol.MatlabConnector.connectFromMatlab(MatlabConnector.java:76)
Caused by: java.net.MalformedURLException: no protocol: Documents/eclipse/MatlabControl/
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at net.jini.loader.pref.PreferredClassProvider.pathToURLs(PreferredClassProvider.java:1186)
at net.jini.loader.pref.PreferredClassProvider.loadClass(PreferredClassProvider.java:298)
at java.rmi.server.RMIClassLoader.loadClass(Unknown Source)
at sun.rmi.server.MarshalInputStream.resolveClass(Unknown Source)
at java.io.ObjectInputStream.readNonProxyDesc(Unknown Source)
at java.io.ObjectInputStream.readClassDesc(Unknown Source)
at java.io.ObjectInputStream.readProxyDesc(Unknown Source)
at java.io.ObjectInputStream.readClassDesc(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
... 2 more
没有分了,各位大大将就将近吧,小弟感激不尽
------解决方案--------------------
解决没有?
今天才知道Matlab连Java原来是通过RMI完成的。