In C#, I use Binary Serialization to send information across the Stream. This is quite simple as all you do is create a class, serialize it and then deserialize it on the receiving end.
My question is, how can I do something similar in C++? All of the network examples I've seen sends a const char * like;
send("LOGIN");
If I wish to send a string and an integer over network, must I really go to the trouble of converting both to a string, putting a command in front of it, and then sending;
[PSEUDO-CODE]
send("COMMAND|" + tostring(someInteger) + "|" + someString);
Then on the receiving end, splitting this string and parsing? I imagine this would get complicated when I have a vector stored and I want to send this over the network.
What can I do?