Set the prune hook, which is the function invoked on the key and value on each eviction. An operation will throw if the pruneHook throws. Note that this prune hook is not automatically called on entries explicitly erase()ed nor on remaining entries at destruction time.
Declared in <folly/container/WeightedEvictingCacheMap.h>
void
setPruneHook(PruneHookCall pruneHook);
| Name | Description |
|---|---|
| pruneHook | eviction callback to set as default, or nullptr to clear |