MCPcopy Create free account
hub / github.com/AutonomousFieldRoboticsLab/SVIn / pop

Method pop

pose_graph/include/utils/ThreadSafeQueue.h:365–374  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

363
364template <typename T>
365bool ThreadsafeQueue<T>::pop(T& value) {
366 if (shutdown_) return false;
367 std::unique_lock<std::mutex> lk(mutex_);
368 if (data_queue_.empty()) return false;
369 value = std::move(*data_queue_.front());
370 data_queue_.pop();
371 lk.unlock(); // Unlock before notify.
372 data_cond_.notify_one();
373 return true;
374}
375
376template <typename T>
377std::shared_ptr<T> ThreadsafeQueue<T>::pop() {

Callers 13

PopBlockingMethod · 0.45
PopNonBlockingMethod · 0.45
PopTimeoutMethod · 0.45
runMethod · 0.45
optimize4DoFPoseGraphMethod · 0.45
optimize6DoFPoseGraphMethod · 0.45
runMethod · 0.45
pushOverflowIfFullMethod · 0.45
popBlockingMethod · 0.45

Calls 1

emptyMethod · 0.45

Tested by

no test coverage detected