WRENCH  1.11
Cyberinfrastructure Simulation Workbench
Overview Installation Getting Started WRENCH 101 WRENCH 102
MessageManager.h
1 
10 #ifdef MESSAGE_MANAGER
11 
12 #ifndef WRENCH_MESSAGEMANAGER_H
13 #define WRENCH_MESSAGEMANAGER_H
14 
15 #include <unordered_set>
16 
17 #include "wrench/services/Service.h"
18 #include "wrench/simulation/SimulationMessage.h"
19 
20 namespace wrench {
21 
22 
23  /***********************/
25  /***********************/
26 
35  class MessageManager {
36 
37  static std::unordered_map<std::string,std::unordered_set<SimulationMessage*>> mailbox_messages;
38 
39  public:
40 
41  static void manageMessage(const std::string &mailbox, SimulationMessage* msg);
42  static void cleanUpMessages(const std::string &mailbox);
43  static void removeReceivedMessage(const std::string &mailbox, SimulationMessage *msg);
44  static void cleanUpAllMessages();
45  static void print();
46 
47  };
48 
49  /***********************/
51  /***********************/
52 }
53 
54 
55 #endif //WRENCH_MESSAGEMANAGER_H
56 
57 #endif //MESSAGE_MANAGER
wrench
Definition: Action.cpp:28