[#BloombergLP-bdlcc-StripedUnorderedMap-update] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlcc.adoc[bdlcc]::xref:BloombergLP/bdlcc/StripedUnorderedMap.adoc[StripedUnorderedMap]::update :relfileprefix: ../../../ :mrdocs: Call `visitor` on the element having `key`, if present. == Synopsis Declared in `<bdlcc_stripedunorderedmap.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- int update( KEY const& key, xref:BloombergLP/bdlcc/StripedUnorderedMap/VisitorFunction.adoc[VisitorFunction] const& visitor); ---- == Description That is: ` bool visitor(&value, key); ` Return the number of elements updated or ‐1 if `visitor` returned `false`. `visitor` has exclusive access (i.e., write access) the element for during its invocation. The behavior is undefined if hash map manipulators and `getValue*` methods are invoked from within `visitor`, as it may lead to a deadlock. DEPRECATED: Use `visit(key, visitor)` instead. == Return Value the number of elements updated, or ‐1 if `visitor` returned `false` == Parameters [cols="1,4"] |=== | Name| Description | *key* | key of the element to visit | *visitor* | functor invoked with the address of the value |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#