BloombergLP::bdljsn::JsonObject::operator[]

Return a non-modifiable reference to the member associated with key.

Synopsis

Declared in <bdljsn_json.h>

Json const&
operator[](std::string_view const& key) const;

Description

Return a reference providing non-modifiable access to the Json object associated with the specified key in this JsonObject. The behavior is undefined unless key is valid UTF-8 (see bdlde::Utf8Util::isValid) and this JsonObject already contains a Json object associated with key.

Return Value

a non-modifiable reference to the element at the specified position

Parameters

NameDescription
keyUTF-8 member name