Serializing Objects for Transmission through a Socket

The desktop version of the .NET Framework allows most types of objects to be serialized into an array of bytes, which can then be sent through a socket. For complex objects, developers implement the ISerializable interface, with code to serialize and deserialize their object data.

The .NET Compact Framework does not support this functionality. The only class that can serialize itself automatically is the DataSet class, which is discussed in detail in Chapter 6, “ADO.NET on the .NET Compact Framework.” Normally, the DataSet class is used as an in-memory relational database. It is ideal for caching small amounts of data from a remote server while preserving the relational structure of the data. ...

Get Microsoft® .NET Compact Framework Kick Start now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.