Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/cplusplus/151.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# c++;c语言中的and WriteTo函数# 我想在C++和C++中使用谷歌原型BooFF。我用原Buff-cPARK端口生成代码,C和C++中的原BUBF代码是由同一个文件生成的。PROTO文件和I用相同的值设置同一个对象。_C#_C++_Visual Studio_Protocol Buffers_Protobuf Csharp Port - Fatal编程技术网

C# c++;c语言中的and WriteTo函数# 我想在C++和C++中使用谷歌原型BooFF。我用原Buff-cPARK端口生成代码,C和C++中的原BUBF代码是由同一个文件生成的。PROTO文件和I用相同的值设置同一个对象。

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#代码: 我想

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语言中的结果不一样,我为什么要这样做。