c# - 如何使用 protobuf-net 处理 .proto 文件

标签 c# ruby protocol-buffers protobuf-net

我已经开始使用 protobuf-net 库在我维护的一些程序之间进行通信。我还能够将消息从 C# 解码为 Ruby。我的 ruby​​ ProtoBuf lib 使用 .proto 文件生成 ruby​​ 代码。为了必须在尽可能少的地方进行更改,我想让 protobuf-net 使用相同的 .proto 文件。查看 protobuf-net 文件夹,有一个名为 ProtoBufGenerator 的 Dll 和 protobuf exe,但我找不到任何关于我是否可以通过这种方式使 protobuf-net 工作的说明。

这可能吗?

最佳答案

查看 Marc Gravell 的博客,this post具体来说。 您基本上将其设置为 Visual Studio 中文件的自定义构建工具。

关于c# - 如何使用 protobuf-net 处理 .proto 文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2822432/

相关文章:

c# - ContentAlignment 枚举值的解释

c# - 数据绑定(bind) Winforms 文本框

ruby - 在 ruby​​ 中包含守卫

c++ - iOS 上的 Google Protocol Buffer

java - Protocol buffer Java解析问题

c# - 我在哪里可以找到一些 "humanized"C# 教程?

c# - 在同一应用程序中使用 VB.NET 和 C#?

ruby-on-rails - 我可以在 Ruby 1.9 上设置默认字符串编码吗?

html - 瓦蒂尔 : How do I find an element where the class of that element and the class of one of its parents identifies it?

protocol-buffers - Apache Thrift、Google Protocol Buffers、MessagePack、ASN.1 和 Apache Avro 之间的主要区别是什么?