protocol-buffers - "1", "2", "3"在protobuf中是什么意思?

标签 protocol-buffers protobuf-net

package tutorial;

message Person {
  required string name = 1;
  required int32 id = 2;
  optional string email = 3;
}

“1”、“2”、“3”是什么意思?

最佳答案

Each field in the message definition has a unique numbered tag. These tags are used to identify your fields in the message binary format, and should not be changed once your message type is in use.



https://web.archive.org/web/20120321055631/http://code.google.com/intl/de-DE/apis/protocolbuffers/docs/proto.html

关于protocol-buffers - "1", "2", "3"在protobuf中是什么意思?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9018274/

相关文章:

protocol-buffers - 使用ProtoContract属性在所有类型上自动执行GetProto的方法

protocol-buffers - Google Protocol Buffer 错误 : "Encountered string containing invalid UTF-8 data while serializing protocol buffer"

cmake - 如何在/include和/src目录下自动移动* .pb.h和* .pb.h?

java - 在使用 java 的客户端服务器的 Protocol Buffer 中需要帮助

c# - Protocol Buffer 反序列化和动态加载的 DLL

go - golang 谷歌 Protocol Buffer 中的错误

c# - 如何使用 Protocol Buffer 的扩展来维护 'general' 消息

c# - 在 Protobuf-net 中装饰中级类

c# - 使用 Protobuf-net 和 Monotouch for IOS 通过 WCF 序列化 IEnumerable

c# - Protobuf-net 使用接口(interface)和抽象基类创建类型模型