C# c++;c语言中的and WriteTo函数# 我想在C++和C++中使用谷歌原型BooFF。我用原Buff-cPARK端口生成代码,C和C++中的原BUBF代码是由同一个文件生成的。PROTO文件和I用相同的值设置同一个对象。
c++代码:C# c++;c语言中的and WriteTo函数# 我想在C++和C++中使用谷歌原型BooFF。我用原Buff-cPARK端口生成代码,C和C++中的原BUBF代码是由同一个文件生成的。PROTO文件和I用相同的值设置同一个对象。,c#,c++,visual-studio,protocol-buffers,protobuf-csharp-port,C#,C++,Visual Studio,Protocol Buffers,Protobuf Csharp Port,c++代码: GetTokenReq getTokenReq; getTokenReq.set_account_name(""); getTokenReq.set_login_type(8); getTokenReq.set_auth_data(""); getTokenReq.set_is_tourist(1); getTokenReq.set_password(g_strPwd); getTokenReq.SerializeToString(&strBody); c#代码: 我想
GetTokenReq getTokenReq;
getTokenReq.set_account_name("");
getTokenReq.set_login_type(8);
getTokenReq.set_auth_data("");
getTokenReq.set_is_tourist(1);
getTokenReq.set_password(g_strPwd);
getTokenReq.SerializeToString(&strBody);
c#代码:
我想将对象序列化为字符串,因此我使用C++中的SerialZeItString函数和CuleEt函数在C语言中。
c++代码:
GetTokenReq getTokenReq;
getTokenReq.set_account_name("");
getTokenReq.set_login_type(8);
getTokenReq.set_auth_data("");
getTokenReq.set_is_tourist(1);
getTokenReq.set_password(g_strPwd);
getTokenReq.SerializeToString(&strBody);
c#代码:
但是,C++中的STRBOST结果与C语言中的结果不一样,我为什么要这样做。