|
◆ operator!= [3/3]
template< template< typename U, typename V, typename... Args > class ObjectType = std::map, template< typename U, typename... Args > class ArrayType = std::vector, class StringType = std::string, class BooleanType = bool, class NumberIntegerType = std::int64_t, class NumberUnsignedType = std::uint64_t, class NumberFloatType = double, template< typename U > class AllocatorType = std::allocator, template< typename T, typename SFINAE= void > class JSONSerializer = adl_serializer>
Compares two JSON values for inequality by calculating not (lhs == rhs) .
- Parameters
-
[in] | lhs | first JSON value to consider |
[in] | rhs | second JSON value to consider |
- Returns
- whether the values lhs and rhs are not equal
- Complexity\n Linear.
- Example\n The example demonstrates comparing several JSON
- types.
18 std::cout << std::boolalpha;
static basic_json array(std::initializer_list< basic_json > init=std::initializer_list< basic_json >()) explicitly create an array from an initializer list
a class to store JSON values
basic_json<> json default JSON class
Output (play with this example online):
[1,2,3] == [1,2,4] true
{"A":"a","B":"b"} == {"A":"a","B":"b"} false
17 == 17 false
"foo" == "bar" true
The example code above can be translated with g++ -std=c++11 -Isrc doc/examples/operator__notequal.cpp -o operator__notequal
- Since
- version 1.0.0
Definition at line 5995 of file json.hpp.
|