[#bsl-unordered_map-0bf-insert-04]
= xref:bsl.adoc[bsl]::xref:bsl/unordered_map-0bf.adoc[unordered&lowbar;map&lt;basic&lowbar;string&lt;char&gt;, Json, TransparentHash, TransparentEqualTo&gt;]::insert
:relfileprefix: ../../
:mrdocs:

Insert the specified `value` into this unordered map if the key (the `first` element) of the object referred to by `value` does not already exist in this unordered map&semi; otherwise, this method has no effect (a `value&lowbar;type` object having the key equivalent to the key of `value` already exists in this unordered map)&period; Return a `pair` whose `first` member is an iterator referring to the (possibly newly inserted) `value&lowbar;type` object in this unordered map whose key is equivalent to that of the object to be inserted, and whose `second` member is `true` if a new value was inserted, and `false` if a value having an equivalent key was already present&period; Note that this method requires that the (template parameter) types `KEY` and `VALUE` both be `copy&hyphen;insertable` into this unordered map (see &lcub;Requirements on `value&lowbar;type`&rcub;)&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;unorderedmap&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
xref:bsl/pair-0b.adoc[pair&lt;iterator, bool&gt;]
insert(xref:bsl/unordered_map-0bf/value_type.adoc[value&lowbar;type] const& value);
----


[.small]#Created with https://www.mrdocs.com[MrDocs]#
