-
Notifications
You must be signed in to change notification settings - Fork 5
About Cereal
Cereal is a header-only serialization library written in C++ and C# by raresica1234 and marcizhu based on TheCherno's serialization library for Java.
The library was done in less than one week, and it was really simple to make because raresica1234 had tried to make a serialization library before. marcizhu had also tried to make one to serialize game data into files, but both failed. After some weeks, we decided to team up and port TheCherno's idea to C++ with a few improvements. For example, the original library only allowed a database per file, which is okay, but we thought that you may need more than one, so after a bit of thinking we made Headers.
This library was originally made for C++, but we needed to serialize data from C#, and we also needed that data to be compatible with the C++ version of Cereal, so we decided to port Cereal to C# too.
Right now both versions are supported, and there are no bugs in any version, although the C# version still needs some testing.
We recommend you to wait until the next release before using the C# version. If you decide to start using the C# version for your projects we would like to get some feedback about it.
Version 1.0.0 (22/10/2016)
- First release of the library
- Added Fields: A field can store just a simple data type. It's the basic serialization unit.
- Added Arrays: An array also has a name, but it can store up to 4.294.967.296 items in it (theoretically, in reality the maximum is 1.073.741.824 items because of x86 architecture). The data types it can store are:
bool
,char
,byte
,short
,int
,long long
,float
anddouble
- Added Objects: An object is a bit more advanced. It has a name, and can store up to 65536 fields plus 65536 arrays.
- Added Database: A database is a collection of objects. It can store up to 65536 objects, but keep in mind that the maximum size of a database is 4 gigabytes, and here's why.
- Added Headers: Headers are completely optional. Headers allow to store up to 255 databases in a single file or memory block, so if you need more than a single database, this is definitely a solution to that.
- Added Buffers: Buffers don't store data. Instead, they can be used as a temporary storage while serializing or deserializing data. Also they are able of reading or writing to files.
Version 1.1.0 (09/12/2016)
- Added
std::string
Arrays. -
NOTE: This update is backwards-compatible: This version can be used to read serialized files with older versions, but previous versions may crash when reading files that have
std::string
arrays.
Home | About Cereal | Setup Guide | Technical Docs | API Reference | Copyright © 2016 - 2019 The Cereal Team