A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
allow to get the number of queued communications in a Mailbox
[simgrid.git]
/
src
/
s4u
/
s4u_Mailbox.cpp
diff --git
a/src/s4u/s4u_Mailbox.cpp
b/src/s4u/s4u_Mailbox.cpp
index
67a26c8
..
7aa76ec
100644
(file)
--- a/
src/s4u/s4u_Mailbox.cpp
+++ b/
src/s4u/s4u_Mailbox.cpp
@@
-39,6
+39,11
@@
bool Mailbox::empty() const
return pimpl_->comm_queue_.empty();
}
+unsigned int Mailbox::size() const
+{
+ return pimpl_->comm_queue_.size();
+}
+
bool Mailbox::listen() const
{
return not this->empty() || (pimpl_->permanent_receiver_ && not pimpl_->done_comm_queue_.empty());