看一段.proto文件里的Message,它们在C#里面对应的是什么类型?
message Person { int32 id = 1; string first_name = 2 // FirstName string last_name = 3; }
Protobuf 类型 | C# 类型 |
double | double |
float | float |
int32 | int |
int64 | long |
uint32 | uint |
uint64 | ulong |
sint32 | int |
sint64 | long |
fixed32 | uint |
fixed64 | ulong |
sfixed32 | int |
sfixed64 | long |
bool | bool |
string | string |
bytes | ByteString |
google.protobuf.Timestamp | DateTimeOffset |
google.protobuf.Timestamp | DateTime |
google.protobuf.Duration | TimeSpan |
标签:google,string,C#,数据类型,int,Message,protobuf From: https://www.cnblogs.com/MingQiu/p/18018896