sqrly
July 20th, 1999, 01:39 PM
I have a socket app working that uses CArchive and CSocket to pass a CMsg object from a client to the server and the other way too. My real app must sent 4 diffent objects. Each is a new config for a diffent PCI/ISA card.
What is the best way to allow the app receiving an object to determine which one of the four it is? I can make the first member variable in each class a tag that identifies it. Then in my serialize(CArchive& ar) function I could read that field and based on it handle the rest.
Anyone have any better Ideas? Could I use TRY/CATCH? I have never used that w/o it being written for me.....newbie to C++.....
Any help would be great.
What is the best way to allow the app receiving an object to determine which one of the four it is? I can make the first member variable in each class a tag that identifies it. Then in my serialize(CArchive& ar) function I could read that field and based on it handle the rest.
Anyone have any better Ideas? Could I use TRY/CATCH? I have never used that w/o it being written for me.....newbie to C++.....
Any help would be great.