[#BloombergLP-bdlcc-Cache-visit]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlcc.adoc[bdlcc]::xref:BloombergLP/bdlcc/Cache.adoc[Cache]::visit
:relfileprefix: ../../../
:mrdocs:

Call the specified `visitor` for every item in this cache&period;

== Synopsis

Declared in `&lt;bdlcc&lowbar;cache&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class VISITOR&gt;
void
visit(VISITOR& visitor) const;
----

== Description

Call the specified `visitor` for every item stored in this cache in the order of the eviction queue until `visitor` returns `false`&period; The `VISITOR` type must be a callable object that can be invoked in the same way as the function `bool (const KEY&amp;, const VALUE&amp;)`&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *visitor*
| callable invoked for each key&hyphen;value pair
|===


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