Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
please sonar, get_clock is a static method
[simgrid.git] / teshsuite / s4u / host-on-off / host-on-off.cpp
index dc0b2de..00f9307 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2020. The SimGrid Team.
+/* Copyright (c) 2010-2021. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
@@ -94,12 +94,12 @@ int main(int argc, char* argv[])
 
   e.load_platform(argv[1]);
 
-  simgrid::s4u::Actor::create("master", simgrid::s4u::Host::by_name("Tremblay"), master);
-  simgrid::s4u::Actor::create("worker", simgrid::s4u::Host::by_name("Jupiter"), worker);
+  simgrid::s4u::Actor::create("master", e.host_by_name("Tremblay"), master);
+  simgrid::s4u::Actor::create("worker", e.host_by_name("Jupiter"), worker);
 
   e.run();
 
-  XBT_INFO("Simulation time %g", e.get_clock());
+  XBT_INFO("Simulation time %g", simgrid::s4u::Engine::get_clock());
 
   return 0;
 }