10 #ifndef WRENCH_NETWORKPROXIMITYMESSAGE_H
11 #define WRENCH_NETWORKPROXIMITYMESSAGE_H
13 #include <wrench/services/network_proximity/NetworkProximityDaemon.h>
14 #include <wrench/services/ServiceMessage.h>
25 class NetworkProximityMessage :
public ServiceMessage {
27 NetworkProximityMessage(std::string name,
double payload);
35 class NetworkProximityLookupRequestMessage :
public NetworkProximityMessage {
37 NetworkProximityLookupRequestMessage(std::string answer_mailbox, std::pair<std::string, std::string> hosts,
41 std::string answer_mailbox;
43 std::pair<std::string, std::string> hosts;
50 class NetworkProximityLookupAnswerMessage :
public NetworkProximityMessage {
52 NetworkProximityLookupAnswerMessage(std::pair<std::string, std::string> hosts,
double proximity_value,
53 double timestamp,
double payload);
56 std::pair<std::string, std::string> hosts;
58 double proximity_value;
67 class NetworkProximityComputeAnswerMessage :
public NetworkProximityMessage {
69 NetworkProximityComputeAnswerMessage(std::pair<std::string, std::string> hosts,
double proximity_value,
73 std::pair<std::string, std::string> hosts;
75 double proximity_value;
81 class NetworkProximityTransferMessage :
public NetworkProximityMessage {
83 NetworkProximityTransferMessage(
double payload);
90 class NextContactDaemonRequestMessage :
public NetworkProximityMessage {
92 NextContactDaemonRequestMessage(std::shared_ptr<NetworkProximityDaemon> daemon,
double payload);
95 std::shared_ptr<NetworkProximityDaemon> daemon;
101 class NextContactDaemonAnswerMessage :
public NetworkProximityMessage {
103 NextContactDaemonAnswerMessage(std::string next_host_to_send,
104 std::shared_ptr<NetworkProximityDaemon> next_daemon_to_send,
105 std::string next_mailbox_to_send,
double payload);
108 std::string next_host_to_send;
111 std::shared_ptr<NetworkProximityDaemon> next_daemon_to_send;
114 std::string next_mailbox_to_send;
120 class CoordinateLookupRequestMessage :
public NetworkProximityMessage {
122 CoordinateLookupRequestMessage(std::string answer_mailbox, std::string requested_host,
double payload);
125 std::string answer_mailbox;
128 std::string requested_host;
134 class CoordinateLookupAnswerMessage :
public NetworkProximityMessage {
136 CoordinateLookupAnswerMessage(std::string requested_host,
bool success, std::pair<double, double> xy_coordinate,
137 double timestamp,
double payload);
140 std::string requested_host;
146 std::pair<double, double> xy_coordinate;
157 #endif //WRENCH_NETWORKPROXIMITYMESSAGE_H