MCPcopy Create free account
hub / github.com/apache/kvrocks / LockGuard

Method LockGuard

src/common/lock_manager.h:86–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84 public:
85 template <typename KeyType>
86 explicit LockGuard(LockManager *lock_mgr, const KeyType &key) : lock_(lock_mgr->Get(key)) {
87 lock_->lock();
88 }
89 ~LockGuard() {
90 if (lock_) lock_->unlock();
91 }

Callers

nothing calls this directly

Calls 1

GetMethod · 0.45

Tested by

no test coverage detected