MCPcopy Create free account
hub / github.com/facebook/CacheLib / operator()

Method operator()

cachelib/object_cache/ObjectCache.h:117–123  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

115 : hdl_(std::move(hdl)) {}
116
117 void operator()(T*) {
118 // Just release the handle.
119 // Cache destroys object when all handles released.
120 std::holds_alternative<ReadHandle>(hdl_)
121 ? std::get<ReadHandle>(hdl_).reset()
122 : std::get<WriteHandle>(hdl_).reset();
123 }
124
125 WriteHandle& getWriteHandleRef() {
126 if (std::holds_alternative<ReadHandle>(hdl_)) {

Callers

nothing calls this directly

Calls 1

resetMethod · 0.45

Tested by

no test coverage detected