Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
sort out the Link::onCommunicate signal
[simgrid.git] / src / surf / network_constant.cpp
index d7dd2ad..fe3356d 100644 (file)
@@ -69,26 +69,20 @@ namespace simgrid {
 
         if (action->getRemainsNoUpdate() <= 0) {
           action->finish();
-          action->setState(SURF_ACTION_DONE);
+          action->setState(Action::State::done);
         } else if ((action->getMaxDuration() != NO_MAX_DURATION)
             && (action->getMaxDuration() <= 0)) {
           action->finish();
-          action->setState(SURF_ACTION_DONE);
+          action->setState(Action::State::done);
         }
       }
     }
 
-    Action *NetworkConstantModel::communicate(NetCard *src, NetCard *dst,
-        double size, double rate)
+    Action *NetworkConstantModel::communicate(NetCard *src, NetCard *dst, double size, double rate)
     {
-      char *src_name = src->name();
-      char *dst_name = dst->name();
-
-      XBT_IN("(%s,%s,%g,%g)", src_name, dst_name, size, rate);
       NetworkConstantAction *action = new NetworkConstantAction(this, size, sg_latency_factor);
-      XBT_OUT();
 
-      networkCommunicateCallbacks(action, src, dst, size, rate);
+      Link::onCommunicate(action, src, dst);
       return action;
     }