简体   繁体   English

在同一台机器上运行的Java和C ++应用程序之间IPC的最佳方法是什么?

[英]What is the best approach for IPC between Java and C++ apps running on the same machine?

I would like to implement a robust IPC solution between a single JVM applet and a C++ application running on the same machine. 我想在单个JVM applet和在同一台机器上运行的C ++应用程序之间实现强大的IPC解决方案。 What is the best approach for doing so? 这样做的最佳方法是什么?

Any suggestions will be greatly appreciated! 任何建议将不胜感激! Thanks! 谢谢!

sockets are about your best (only reasonable?) choice. 套接字是你最好的(唯一合理的?)选择。 although if you are running an applet, you will have to deal with access permissions issues (signing the applet will probably solve these). 虽然如果您正在运行applet,您将不得不处理访问权限问题(签署applet可能会解决这些问题)。

Sockets as a transport protocol. 套接字作为传输协议。

JSON as a message protocol, with optional length header or trailing zero if required. JSON作为消息协议,如果需要,可选长度标题或尾随零。

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

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