MCPcopy Create free account
hub / github.com/apache/arrow / Pop

Method Pop

cpp/src/arrow/flight/sql/odbc/odbc_impl/blocking_queue.h:84–96  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

82 }
83
84 bool Pop(T* result) {
85 std::unique_lock<std::mutex> unique_lock(mtx_);
86 if (!WaitUntilCanPopOrClosed(unique_lock)) return false;
87
88 *result = std::move(buffer_[left_]);
89
90 left_ = (left_ + 1) % capacity_;
91 buffer_size_--;
92
93 not_full_.notify_one();
94
95 return true;
96 }
97
98 void Close() {
99 std::unique_lock<std::mutex> unique_lock(mtx_);

Callers 1

GetNextMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected