[#bsl-map-0a7-contains-06] = xref:bsl.adoc[bsl]::xref:bsl/map-0a7.adoc[map]::contains :relfileprefix: ../../ :mrdocs: Return whether this map contains an element equivalent to `key`. == Synopses Declared in `<bslstl_map.h>` Return whether this map contains an element equivalent to `key`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- bool xref:bsl/map-0a7/contains-01.adoc[contains](xref:bsl/map-0a7/key_type.adoc[key_type] const& key) const; ---- [.small]#xref:bsl/map-0a7/contains-01.adoc[_» more..._]# Return whether this map contains an element equivalent to `key`. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class LOOKUP_KEY> bool xref:bsl/map-0a7/contains-00.adoc[contains](LOOKUP_KEY const& key) const requires BloombergLP::bslmf::IsTransparentPredicate<COMPARATOR, LOOKUP_KEY>::value; ---- [.small]#xref:bsl/map-0a7/contains-00.adoc[_» more..._]# == Return Value `true` if an equivalent key is present == Parameters [cols="1,4"] |=== | Name| Description | *key* | key value to look up |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#