{"id":13417891,"url":"https://github.com/USCiLab/cereal","last_synced_at":"2025-03-15T02:31:57.643Z","repository":{"id":9157791,"uuid":"10952997","full_name":"USCiLab/cereal","owner":"USCiLab","description":"A C++11 library for serialization","archived":false,"fork":false,"pushed_at":"2024-08-19T12:53:39.000Z","size":18493,"stargazers_count":4212,"open_issues_count":320,"forks_count":758,"subscribers_count":152,"default_branch":"master","last_synced_at":"2024-10-22T21:43:08.325Z","etag":null,"topics":["c-plus-plus","cereal","serialization"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/USCiLab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-06-25T23:18:45.000Z","updated_at":"2024-10-22T06:20:56.000Z","dependencies_parsed_at":"2024-05-02T00:53:22.014Z","dependency_job_id":"323d247f-890b-40d5-a252-8963f303bf7d","html_url":"https://github.com/USCiLab/cereal","commit_stats":{"total_commits":835,"total_committers":83,"mean_commits":"10.060240963855422","dds":0.3916167664670659,"last_synced_commit":"d1fcec807b372f04e4c1041b3058e11c12853e6e"},"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USCiLab%2Fcereal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USCiLab%2Fcereal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USCiLab%2Fcereal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/USCiLab%2Fcereal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/USCiLab","download_url":"https://codeload.github.com/USCiLab/cereal/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221532167,"owners_count":16838907,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c-plus-plus","cereal","serialization"],"created_at":"2024-07-30T22:00:54.865Z","updated_at":"2024-10-26T12:31:06.457Z","avatar_url":"https://github.com/USCiLab.png","language":"C++","readme":"cereal - A C++11 library for serialization\n==========================================\n\n\u003cimg src=\"https://uscilab.github.io/cereal/assets/img/cerealboxside.png\" align=\"right\"/\u003e\u003cp\u003ecereal is a header-only C++11 serialization library.  cereal takes arbitrary data types and reversibly turns them into different representations, such as compact binary encodings, XML, or JSON.  cereal was designed to be fast, light-weight, and easy to extend - it has no external dependencies and can be easily bundled with other code or used standalone.\u003c/p\u003e\n\n### cereal has great documentation\n\nLooking for more information on how cereal works and its documentation?  Visit [cereal's web page](https://USCiLab.github.io/cereal) to get the latest information.\n\n### cereal is easy to use\n\nInstallation and use of of cereal is fully documented on the [main web page](https://USCiLab.github.io/cereal), but this is a quick and dirty version:\n\n* Download cereal and place the headers somewhere your code can see them\n* Write serialization functions for your custom types or use the built in support for the standard library cereal provides\n* Use the serialization archives to load and save data\n\n```cpp\n#include \u003ccereal/types/unordered_map.hpp\u003e\n#include \u003ccereal/types/memory.hpp\u003e\n#include \u003ccereal/archives/binary.hpp\u003e\n#include \u003cfstream\u003e\n    \nstruct MyRecord\n{\n  uint8_t x, y;\n  float z;\n  \n  template \u003cclass Archive\u003e\n  void serialize( Archive \u0026 ar )\n  {\n    ar( x, y, z );\n  }\n};\n    \nstruct SomeData\n{\n  int32_t id;\n  std::shared_ptr\u003cstd::unordered_map\u003cuint32_t, MyRecord\u003e\u003e data;\n  \n  template \u003cclass Archive\u003e\n  void save( Archive \u0026 ar ) const\n  {\n    ar( data );\n  }\n      \n  template \u003cclass Archive\u003e\n  void load( Archive \u0026 ar )\n  {\n    static int32_t idGen = 0;\n    id = idGen++;\n    ar( data );\n  }\n};\n\nint main()\n{\n  std::ofstream os(\"out.cereal\", std::ios::binary);\n  cereal::BinaryOutputArchive archive( os );\n\n  SomeData myData;\n  archive( myData );\n\n  return 0;\n}\n```    \n\n### cereal has a mailing list\n\nEither get in touch over \u003ca href=\"mailto:cerealcpp@googlegroups.com\"\u003eemail\u003c/a\u003e or [on the web](https://groups.google.com/forum/#!forum/cerealcpp).\n\n\n\n## cereal has a permissive license\n\ncereal is licensed under the [BSD license](http://opensource.org/licenses/BSD-3-Clause).\n\n## cereal build status\n\n* [![Linux build status](https://github.com/USCiLab/cereal/actions/workflows/ci.yml/badge.svg)](https://github.com/USCiLab/cereal/actions/workflows/ci.yml)\n* [![Mac build status](https://github.com/USCiLab/cereal/actions/workflows/ci-macos.yml/badge.svg)](https://github.com/USCiLab/cereal/actions/workflows/ci-macos.yml)\n* [![Windows build status](https://ci.appveyor.com/api/projects/status/91aou6smj36or0vb/branch/master?svg=true)](https://ci.appveyor.com/project/AzothAmmo/cereal/branch/master)\n\n---\n\nWere you looking for the Haskell cereal?  Go \u003ca href=\"https://github.com/GaloisInc/cereal\"\u003ehere\u003c/a\u003e.\n","funding_links":[],"categories":["C++","TODO scan for Android support in followings","Serialization","C/C++","Objects - Entity, Actor","正则表达式","序列化","C/C++程序设计","Libraries"],"sub_categories":["Miscs","Saving/Loading Objects, Compositing Packets","序列化","资源传输下载","C++","Parsing \u0026 Serialization"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FUSCiLab%2Fcereal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FUSCiLab%2Fcereal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FUSCiLab%2Fcereal/lists"}