Hazelcast C++ Client
|
HazelcastJsonValue is a wrapper for Json formatted strings. More...
#include <HazelcastJsonValue.h>
Public Member Functions | |
HazelcastJsonValue (const std::string &jsonString) | |
Create a HazelcastJsonValue from a string. More... | |
const std::string & | toString () const |
This method returns a Json representation of the object. More... | |
bool | operator== (const HazelcastJsonValue &rhs) const |
bool | operator!= (const HazelcastJsonValue &rhs) const |
Friends | |
std::ostream HAZELCAST_API & | operator<< (std::ostream &os, const HazelcastJsonValue &value) |
HazelcastJsonValue is a wrapper for Json formatted strings.
It is preferred to store HazelcastJsonValue instead of std::string for Json formatted strings. Users can run predicates and use indexes on the attributes of the underlying Json strings.
HazelcastJsonValue is queried using Hazelcast's querying language. See query::Predicate.
In terms of querying, numbers in Json strings are treated as either
or
. Strings, bools and NULL are treated as their C++ counterparts.
HazelcastJsonValue keeps given string as it is.
hazelcast::client::HazelcastJsonValue::HazelcastJsonValue | ( | const std::string & | jsonString | ) |
Create a HazelcastJsonValue from a string.
This method does not the check validity of the underlying Json string. Invalid Json strings may cause wrong results in queries.
jsonString | The json string |
const std::string & hazelcast::client::HazelcastJsonValue::toString | ( | ) | const |
This method returns a Json representation of the object.