Commit Graph

120 Commits

Author SHA1 Message Date
Martchus 5e95127185 Exclude tuple from the types considered 'user defined' 2017-10-29 21:41:18 +01:00
Martchus ae3d8030b6 Allow serializing enums
Note that deserializing is not so simple because
we would need to check whether the integer actually
is an item of the expected enumeration type.
2017-10-29 21:31:23 +01:00
Martchus 0520341411 Fix passing temporary to Reflector::push() 2017-10-28 18:29:15 +02:00
Martchus 104e362762 Imporve documentation and build script 2017-10-28 18:24:12 +02:00
Martchus c94c896f6c Refactor RapidJSON wrapper
* Move all JSON related files into own directory
* Move helper for error handling in own header
* Remove some leftovers from debugging
* Rename classes, use Json instead of JSON
2017-10-28 16:23:39 +02:00
Martchus 5d441cf5ab Fix Boost.Hana tests
Boost.Hana doesn't make the record name accessible so
it can not be provided in the error case.
2017-10-28 15:53:16 +02:00
Martchus ad03afb1f2 Keep track of errors and fix usage of Boost.Hana
* Optionally save errors which occur during deserialization
  to allow error handling
* Don't operate on copies when using Boost.Hana
2017-10-28 15:50:16 +02:00
Martchus 1b1d07ef8c Improve error handling
* Throw ParseResult when parsing error occurs
* Silence type mismatch or missing members for now
2017-10-27 20:59:08 +02:00
Martchus 97f1dc57cf Make use of reserve() and size() if possible 2017-10-27 18:26:36 +02:00
Martchus 31c37a8ee4 Add helper to ease disambiguation 2017-10-27 15:48:55 +02:00
Martchus ef6a91076f Apply clang-format 2017-10-27 15:48:26 +02:00
Martchus 34779dcf4b Remove unused files 2017-10-25 19:23:50 +02:00
Martchus 8922c26c3d Add some documentation 2017-10-25 19:18:13 +02:00
Martchus 0d17d5f20b Allow using Boost.Hana instead of code generator 2017-10-25 19:16:55 +02:00
Martchus b725f59e78 Rename moc -> generator 2017-10-25 17:41:19 +02:00
Martchus 3889031247 Handle multiple input files correctly
by invoking the generator multiple times
2017-10-25 17:32:03 +02:00
Martchus 617ee58b91 Clear interatables before pulling array elements 2017-10-25 16:37:49 +02:00
Martchus 8679263f09 Add CMake macro and actually test the generated code 2017-10-24 01:00:40 +02:00
Martchus 4a8ebc99a3 Rename Reflectable -> JSONSerializable
This allows to provide multiple independently
functional reflection features by simply using
different base classes for them.
2017-10-23 00:41:10 +02:00
Martchus 8344a99778 Add project basic project structure
* Implement simple RapidJSON wrapper
* Add skeleton for code generator to play around with
  LibTooling and LibClang
2017-10-19 01:10:51 +02:00