Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
sanitize surf API: s/updateState/apply_event/
[simgrid.git] / src / surf / host_ptask_L07.cpp
index ece1449..a02f7b5 100644 (file)
@@ -89,7 +89,7 @@ NetworkL07Model::~NetworkL07Model()
 }
 
 
-double HostL07Model::shareResources(double /*now*/)
+double HostL07Model::next_occuring_event(double /*now*/)
 {
   L07Action *action;
 
@@ -408,14 +408,11 @@ CpuL07::~CpuL07()
 }
 
 LinkL07::LinkL07(NetworkL07Model *model, const char* name, xbt_dict_t props,
-             double bw_initial,
-             tmgr_trace_t bw_trace,
-             double lat_initial,
-             tmgr_trace_t lat_trace,
-             int initiallyOn,
-             tmgr_trace_t state_trace,
+             double bw_initial, tmgr_trace_t bw_trace,
+             double lat_initial, tmgr_trace_t lat_trace,
+             int initiallyOn, tmgr_trace_t state_trace,
              e_surf_link_sharing_policy_t policy)
- : Link(model, name, props, lmm_constraint_new(model->getMaxminSystem(), this, bw_initial), future_evt_set, state_trace)
+ : Link(model, name, props, lmm_constraint_new(model->getMaxminSystem(), this, bw_initial), state_trace)
 {
   m_bandwidth.peak = bw_initial;
   if (bw_trace)
@@ -483,7 +480,7 @@ bool LinkL07::isUsed(){
   return lmm_constraint_used(getModel()->getMaxminSystem(), getConstraint());
 }
 
-void CpuL07::updateState(tmgr_trace_iterator_t triggered, double value, double /*date*/){
+void CpuL07::apply_event(tmgr_trace_iterator_t triggered, double value){
   XBT_DEBUG("Updating cpu %s (%p) with value %g", getName(), this, value);
   if (triggered == p_speedEvent) {
     m_speedScale = value;
@@ -500,13 +497,13 @@ void CpuL07::updateState(tmgr_trace_iterator_t triggered, double value, double /
   }
 }
 
-void LinkL07::updateState(tmgr_trace_iterator_t triggered, double value, double date) {
-  XBT_DEBUG("Updating link %s (%p) with value=%f for date=%g", getName(), this, value, date);
+void LinkL07::apply_event(tmgr_trace_iterator_t triggered, double value) {
+  XBT_DEBUG("Updating link %s (%p) with value=%f", getName(), this, value);
   if (triggered == m_bandwidth.event) {
-    updateBandwidth(value, date);
+    updateBandwidth(value);
     tmgr_trace_event_unref(&m_bandwidth.event);
   } else if (triggered == m_latency.event) {
-    updateLatency(value, date);
+    updateLatency(value);
     tmgr_trace_event_unref(&m_latency.event);
   } else if (triggered == m_stateEvent) {
     if (value > 0)
@@ -519,13 +516,13 @@ void LinkL07::updateState(tmgr_trace_iterator_t triggered, double value, double
   }
 }
 
-void LinkL07::updateBandwidth(double value, double date)
+void LinkL07::updateBandwidth(double value)
 {
   m_bandwidth.peak = value;
   lmm_update_constraint_bound(getModel()->getMaxminSystem(), getConstraint(), m_bandwidth.peak * m_bandwidth.scale);
 }
 
-void LinkL07::updateLatency(double value, double date)
+void LinkL07::updateLatency(double value)
 {
   lmm_variable_t var = NULL;
   L07Action *action;