|
|
type | t () const |
| |
|
| wvalue (std::nullptr_t) |
| |
|
| wvalue (bool value) |
| |
|
| wvalue (std::uint8_t value) |
| |
|
| wvalue (std::uint16_t value) |
| |
|
| wvalue (std::uint32_t value) |
| |
|
| wvalue (std::uint64_t value) |
| |
|
| wvalue (std::int8_t value) |
| |
|
| wvalue (std::int16_t value) |
| |
|
| wvalue (std::int32_t value) |
| |
|
| wvalue (std::int64_t value) |
| |
|
| wvalue (float value) |
| |
|
| wvalue (double value) |
| |
|
| wvalue (char const *value) |
| |
|
| wvalue (std::string const &value) |
| |
|
| wvalue (std::string &&value) |
| |
|
| wvalue (std::initializer_list< std::pair< std::string const, wvalue > > initializer_list) |
| |
|
| wvalue (object const &value) |
| |
|
| wvalue (object &&value) |
| |
|
| wvalue (const list &r) |
| |
|
| wvalue (list &r) |
| |
|
| wvalue (const rvalue &r) |
| | Create a write value from a read value (useful for editing JSON strings).
|
| |
|
| wvalue (const wvalue &r) |
| |
|
| wvalue (wvalue &&r) |
| |
|
wvalue & | operator= (wvalue &&r) |
| |
|
void | clear () |
| | Used for compatibility, same as reset()
|
| |
|
void | reset () |
| |
|
wvalue & | operator= (std::nullptr_t) |
| |
|
wvalue & | operator= (bool value) |
| |
|
wvalue & | operator= (float value) |
| |
|
wvalue & | operator= (double value) |
| |
|
wvalue & | operator= (unsigned short value) |
| |
|
wvalue & | operator= (short value) |
| |
|
wvalue & | operator= (long long value) |
| |
|
wvalue & | operator= (long value) |
| |
|
wvalue & | operator= (int value) |
| |
|
wvalue & | operator= (unsigned long long value) |
| |
|
wvalue & | operator= (unsigned long value) |
| |
|
wvalue & | operator= (unsigned int value) |
| |
|
wvalue & | operator= (const char *str) |
| |
|
wvalue & | operator= (const std::string &str) |
| |
|
wvalue & | operator= (list &&v) |
| |
|
template<typename T > |
| wvalue & | operator= (const std::vector< T > &v) |
| |
|
wvalue & | operator= (std::initializer_list< std::pair< std::string const, wvalue > > initializer_list) |
| |
|
wvalue & | operator= (object const &value) |
| |
|
wvalue & | operator= (object &&value) |
| |
|
wvalue & | operator= (std::function< std::string(std::string &)> &&func) |
| |
|
wvalue & | operator[] (unsigned index) |
| |
|
const wvalue & | operator[] (unsigned index) const |
| |
|
bool | has (const char *key) const |
| | Check if the object contains the given key.
|
| |
|
bool | has (const std::string &key) const |
| | Check if the object contains the given key.
|
| |
|
size_t | count (const std::string &str) const |
| |
|
wvalue & | operator[] (const std::string &str) |
| |
|
const wvalue & | operator[] (const std::string &str) const |
| |
|
std::vector< std::string > | keys () const |
| |
|
std::string | execute (std::string txt="") const |
| |
|
std::size_t | size () const |
| | If the wvalue is a list, it returns the length of the list, otherwise it returns 1.
|
| |
|
size_t | estimate_length () const |
| | Returns an estimated size of the value in bytes.
|
| |
|
std::string | dump (const size_t indent, const char separator=' ') const |
| |
| std::string | dump () const override |
| |
|
| operator std::string () const |
| | Return json string.
|
| |
|
| returnable (std::string ctype) |
| |
JSON write value.
Value can mean any json value, including a JSON object.
Write means this class is used to primarily assemble JSON objects using keys and values and export those into a string. The object container is selected at compile time. By default, object keys use an std::unordered_map; CROW_JSON_USE_MAP selects lexicographically sorted keys, while CROW_JSON_USE_INSERTION_ORDER preserves the order of newly inserted keys. Updating an existing key does not change its position. These options affect the order of serialized JSON object keys and cannot be used together.