使用 Java (DCOM) 远程访问 COM 服务器 (EXE)
我有一个关于远程访问 COM 对象的问题。目前我正在使用 JACOB 连接我们的自定义 COM 服务器(exe),它工作得非常好。然而,我们试图将 Java 代码与 COM 服务器分开,并将它们放置在不同的机器上。 JACOB 不支持 DCOM。所以我想知道 com4j 可以吗?如果是这样,你可以指出一些链接等。我已经尝试过使用 j-interop 并且讨厌它,因为它非常冗长且完全不直观。
另外,当我使用“组件服务”> 访问 COM 服务器的属性时, DCOM+ 配置位置选项卡选项“在以下计算机上运行应用程序”是什么意思?这是否意味着所选计算机上还必须有 COM Server (exe)?这似乎是多余的。
最后,还有其他免费的开源库可以实现我想要实现的功能吗?
感谢您的时间和帮助。
I have a question about accessing COM objects remotely. Currently I am using JACOB to connect our custom COM server (exe) and it works really well. However we are trying to separate the Java code from the COM server and place them on separate machines. JACOB doesn't support DCOM. So I wanted to know is this possible with com4j? If so can you point to some links, etc. I have already tried using j-interop and hate it since it is extremely verbose and totally non-intuitive.
Also when I access the COM server's properties using the Component Services > DCOM+ Config what does the location tab option "Run Application on the following Computer" mean? Does it mean that the computer selected must also have the COM Server (exe) on it? This would seem redundant.
Lastly are there any other free open source libraries out there that will allow the functionality I am trying to acheieve?
Thanks for your time and help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
查看 j-interop 代理(https://github.com/kohsuke/jinterop-proxy),这使得 j-interop 调用变得不那么冗长。您可以在 Hudson 项目中找到使用示例。
Check out j-interop proxy (https://github.com/kohsuke/jinterop-proxy), this makes j-interop calls a lot less verbose. You can find usage examples in the Hudson project.