加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Linux > 正文

是否有可能我们可以使用远程方法调用将Linux中的C程序传递给充当

发布时间:2020-12-14 01:36:45 所属栏目:Linux 来源:网络整理
导读:是否有可能在 Linux OS中运行的C程序(客户端程序)与使用RMI实现的Windows中运行的C#程序(服务器程序)之间实现客户端/服务器通信?任何人都可以建议任何可能的方式…任何有用的参考很受欢迎 解决方法 您需要遵循Google Protobuf的规定.它也适用于C和 C#. 来自
是否有可能在 Linux OS中运行的C程序(客户端程序)与使用RMI实现的Windows中运行的C#程序(服务器程序)之间实现客户端/服务器通信?任何人都可以建议任何可能的方式…任何有用的参考很受欢迎

解决方法

您需要遵循Google Protobuf的规定.它也适用于C和 C#.

来自MSDN的类似答案

It does not matter if you send data from java,c++ or c#,when it goes
over the network it’s just 1s and 0s. It’s a matter of what you do
with it on the client/server side. So,be sure that the data that you
receive corresponds with the structure that you have (that you want to
deserialize to).

Sometimes you need to manually put the bits and bytes together to get
it all working out. However,there is something called “Protobuff”
that can help you get a common structure of the data that you send,
google it and read all about it.

您可以使用套接字实现客户端服务器,并使用protobuf对其进行序列化/反序列化.(MSDN链接可能有助于解决方案)

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读