In computer science, in the context of data storage, serialization is the process of translating data structures or object state into a format that can be stored (for example, in a file or memory buffer) or transmitted (for example, across a network connection link) and reconstructed later (possibly in a different computer environment). When the resulting series of bits is reread according to the serialization format, it can be used to create a semantically identical clone of the original object. For many complex objects, such as those that make extensive use of references, this process is not straightforward. Serialization of object-oriented objects does not include any of their associated methods with which they were previously linked.
There are several use cases for Serialization, such as storing settings, user information and data transfer, here is a generic list of Serialization use cases:
- A method of transferring data through the wires (messaging).
- A method of storing data (in databases, on hard disk drives).
- A method of remote procedure calls, e.g., as in SOAP.
- A method for distributing objects, especially in component-based software engineering such as COM, CORBA, etc.
- A method for detecting changes in time-varying data.
One of most important use case of Serialization is storing data on storage (database or hard disk drive).
Serialization in Game Development is mostly used for storing data, such as storing player data like Health, Score, Level, … at user storage.
There are many Serialization formats out there, but some of them are popular and useful, like Binary, JSON, XML and YAML, and some Programming languages has built-in support for some Serialization formats, like C# has built-in support for XML and Binary.
There is a good Comparison of data serialization formats at Wikipedia.
Here is a list of Serialization formats with their official website:
Binary Serialization format has no website, because it is not invented by someone, it is a traditional format that is used at lowest level of computation, Binary is called the digital representation of text and data, have a look at the below articles to find out more about Binary:
Each Byte is 8 bit that bit is represented by 0 or 1 symbols that the combination of Bytes represents the data and the Bytes Array is called Binary.
There is no specifications for Binary, But some Character Encoding specifications provide some rules that should be followed, Here is a example of Binary-to-text encoding, Also, there is a list of Encoding standards.
Thanks for reading.