BloombergLP::bdljsn::Json::contains

Return whether the held object contains a member with key.

Synopsis

Declared in <bdljsn_json.h>

bool
contains(std::string_view const& key) const;

Description

Return true if the JsonObject held by this Json object contains a member whose key is equivalent to the specified key, and return false otherwise. The behavior is undefined unless true == isObject().

Return Value

true if a member with the specified key is present, and false otherwise

Parameters

NameDescription
keyUTF-8 member name