11 #ifndef WRENCH_S4U_MAILBOX_H
12 #define WRENCH_S4U_MAILBOX_H
19 #include <simgrid/s4u.hpp>
27 class SimulationMessage;
28 class S4U_PendingCommunication;
36 static std::unique_ptr<SimulationMessage>
getMessage(std::string mailbox);
37 static std::unique_ptr<SimulationMessage>
getMessage(std::string mailbox,
double timeout);
41 static std::shared_ptr<S4U_PendingCommunication>
igetMessage(std::string mailbox_name);
60 #endif //WRENCH_S4U_MAILBOX_H
static std::string generateUniqueMailboxName(std::string)
Generate a unique mailbox name given a prefix (this method simply appends an increasing sequence numb...
Definition: S4U_Mailbox.cpp:252
static void dputMessage(std::string mailbox_name, SimulationMessage *msg)
Asynchronously send a message to a mailbox in a "fire and forget" fashion.
Definition: S4U_Mailbox.cpp:142
Wrappers around S4U's communication methods.
Definition: S4U_Mailbox.h:33
static std::shared_ptr< S4U_PendingCommunication > igetMessage(std::string mailbox_name)
Asynchronously receive a message from a mailbox.
Definition: S4U_Mailbox.cpp:212
Top-level class to describe a message communicated by processes in the simulation.
Definition: SimulationMessage.h:27
static std::unique_ptr< SimulationMessage > getMessage(std::string mailbox)
Synchronously receive a message from a mailbox.
Definition: S4U_Mailbox.cpp:44
static void putMessage(std::string mailbox, SimulationMessage *m)
Synchronously send a message to a mailbox.
Definition: S4U_Mailbox.cpp:115
static std::shared_ptr< S4U_PendingCommunication > iputMessage(std::string mailbox_name, SimulationMessage *msg)
Asynchronously send a message to a mailbox.
Definition: S4U_Mailbox.cpp:177
static unsigned long generateUniqueSequenceNumber()
Generate a unique sequence number.
Definition: S4U_Mailbox.cpp:239