CppSerialization
1.0.4.0
C++ Serialization Library
|
#include <serializer.h>
Public Member Functions | |
Serializer ()=default | |
Serializer (OutputStream &stream) | |
Serializer (const Serializer &)=delete | |
Serializer (Serializer &&)=default | |
~Serializer ()=default | |
Serializer & | operator= (const Serializer &)=delete |
Serializer & | operator= (Serializer &&)=default |
void | StartObject () |
Start new object. More... | |
void | EndObject () |
End the current object. More... | |
void | StartArray () |
Start new array. More... | |
void | EndArray () |
End the current array. More... | |
void | Key (const char *key) |
Put the C-string key. More... | |
void | Key (const char *key, size_t size) |
Put the C-string key with a given size. More... | |
void | Key (const std::string &key) |
Put the string key. More... | |
template<std::size_t N> | |
void | Key (const char(&key)[N]) |
Put the fixed string array key. More... | |
void | Value (std::nullptr_t value) |
Put the null value. More... | |
void | Value (bool value) |
Put the boolean value. More... | |
void | Value (int value) |
Put the integer value. More... | |
void | Value (unsigned value) |
Put the unsigned integer value. More... | |
void | Value (int64_t value) |
Put the 64-bit integer value. More... | |
void | Value (uint64_t value) |
Put the 64-bit unsigned integer value. More... | |
void | Value (double value) |
Put the double value. More... | |
void | Value (const char *value) |
Put the C-string value. More... | |
void | Value (const char *value, size_t size) |
Put the C-string value with a given size. More... | |
void | Value (const std::string &value) |
Put the string value. More... | |
template<std::size_t N> | |
void | Value (const char(&value)[N]) |
Put the fixed string array value. More... | |
void | Pair (const char *key, std::nullptr_t value) |
Put the null key/value pair. More... | |
void | Pair (const char *key, bool value) |
Put the boolean key/value pair. More... | |
void | Pair (const char *key, int value) |
Put the integer key/value pair. More... | |
void | Pair (const char *key, unsigned value) |
Put the unsigned integer key/value pair. More... | |
void | Pair (const char *key, int64_t value) |
Put the 64-bit integer key/value pair. More... | |
void | Pair (const char *key, uint64_t value) |
Put the 64-bit unsigned integer key/value pair. More... | |
void | Pair (const char *key, double value) |
Put the double key/value pair. More... | |
void | Pair (const char *key, const char *value) |
Put the C-string key/value pair. More... | |
void | Pair (const char *key, const char *value, size_t size) |
Put the C-string key/value pair with a given size. More... | |
void | Pair (const char *key, const std::string &value) |
Put the string key/value pair. More... | |
template<std::size_t N> | |
void | Pair (const char *key, const char(&value)[N]) |
Put the fixed string array key/value pair. More... | |
JSON serializer.
JSON serializer is parametrized with an output stream and is used to serialize objects into JSON format.
Definition at line 23 of file serializer.h.
|
default |
|
inlineexplicit |
Definition at line 27 of file serializer.h.
|
delete |
|
default |
|
default |
|
inline |
End the current array.
Definition at line 34 of file serializer.inl.
|
inline |
End the current object.
Definition at line 20 of file serializer.inl.
|
inline |
Put the C-string key.
Definition at line 41 of file serializer.inl.
|
inline |
Put the C-string key with a given size.
Definition at line 48 of file serializer.inl.
|
inline |
Put the fixed string array key.
Definition at line 63 of file serializer.inl.
|
inline |
Put the string key.
Definition at line 55 of file serializer.inl.
|
delete |
|
default |
|
inline |
Put the boolean key/value pair.
Definition at line 83 of file serializer.h.
|
inline |
Put the C-string key/value pair.
Definition at line 101 of file serializer.h.
|
inline |
Put the C-string key/value pair with a given size.
Definition at line 104 of file serializer.h.
|
inline |
Put the fixed string array key/value pair.
Definition at line 111 of file serializer.h.
|
inline |
Put the string key/value pair.
Definition at line 107 of file serializer.h.
|
inline |
Put the double key/value pair.
Definition at line 98 of file serializer.h.
|
inline |
Put the integer key/value pair.
Definition at line 86 of file serializer.h.
|
inline |
Put the 64-bit integer key/value pair.
Definition at line 92 of file serializer.h.
|
inline |
Put the null key/value pair.
Definition at line 80 of file serializer.h.
|
inline |
Put the 64-bit unsigned integer key/value pair.
Definition at line 95 of file serializer.h.
|
inline |
Put the unsigned integer key/value pair.
Definition at line 89 of file serializer.h.
|
inline |
Start new array.
Definition at line 27 of file serializer.inl.
|
inline |
Start new object.
Definition at line 13 of file serializer.inl.
|
inline |
Put the boolean value.
Definition at line 77 of file serializer.inl.
|
inline |
Put the C-string value.
Definition at line 119 of file serializer.inl.
|
inline |
Put the C-string value with a given size.
Definition at line 126 of file serializer.inl.
|
inline |
Put the fixed string array value.
Definition at line 141 of file serializer.inl.
|
inline |
Put the string value.
Definition at line 133 of file serializer.inl.
|
inline |
Put the double value.
Definition at line 112 of file serializer.inl.
|
inline |
Put the integer value.
Definition at line 84 of file serializer.inl.
|
inline |
Put the 64-bit integer value.
Definition at line 98 of file serializer.inl.
|
inline |
Put the null value.
Definition at line 70 of file serializer.inl.
|
inline |
Put the 64-bit unsigned integer value.
Definition at line 105 of file serializer.inl.
|
inline |
Put the unsigned integer value.
Definition at line 91 of file serializer.inl.