Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/chenshuo/muduo
/ put
Method
put
muduo/base/BoundedBlockingQueue.h:30–40 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
28
}
29
30
void put(const T& x)
31
{
32
MutexLockGuard lock(mutex_);
33
while (queue_.full())
34
{
35
notFull_.wait();
36
}
37
assert(!queue_.full());
38
queue_.push_back(x);
39
notEmpty_.notify();
40
}
41
42
void put(T&& x)
43
{
Callers
nothing calls this directly
Calls
3
full
Method · 0.80
notify
Method · 0.80
wait
Method · 0.45
Tested by
no test coverage detected