java matlab如何在matlab脚本中运行jar? [英] java matlab how can I run a jar inside a matlab script?

查看:505
本文介绍了java matlab如何在matlab脚本中运行jar?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个jar,它基本上解析了一堆pdf /文本文件并创建了一个.mat文件。我还有一个matlab脚本,可以加载.mat文件并将数据与其他一些数据进行比较。我想确保jar运行并首先更新.mat文件。我希望我的matlab脚本的第一行执行jar并等待它完成。我该怎么做呢?

I created a jar that basically parses a bunch of pdf/text files and creates a .mat file. I also have a matlab script that loads that .mat file and compares the data against some other data. I want to ensure that the jar runs and updates the .mat file first. I want the first line of my matlab script to execute the jar and wait for it to complete. How do I do this?

推荐答案

我通过使用system('java -jar jarname.jar')来运行它

I got it to run by using system('java -jar jarname.jar')

这篇关于java matlab如何在matlab脚本中运行jar?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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