Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
allow to get the number of queued communications in a Mailbox
[simgrid.git] / src / s4u / s4u_Mailbox.cpp
index 67a26c8..7aa76ec 100644 (file)
@@ -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());