X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/f9940d69db992aa3bb82ed541b8c511f18ca4eca..808fd3fed0409880a319cae9b6c3ca115c1c01d1:/examples/s4u/energy-link/s4u-energy-link.cpp diff --git a/examples/s4u/energy-link/s4u-energy-link.cpp b/examples/s4u/energy-link/s4u-energy-link.cpp index 37af2797fc..a927e1f1b9 100644 --- a/examples/s4u/energy-link/s4u-energy-link.cpp +++ b/examples/s4u/energy-link/s4u-energy-link.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2017-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -22,7 +22,7 @@ static void sender(std::vector args) double comm_size = std::stod(args.at(1)); XBT_INFO("Send %.0f bytes, in %d flows", comm_size, flow_amount); - simgrid::s4u::MailboxPtr mailbox = simgrid::s4u::Mailbox::byName(std::string("message")); + simgrid::s4u::MailboxPtr mailbox = simgrid::s4u::Mailbox::by_name(std::string("message")); /* Sleep a while before starting the example */ simgrid::s4u::this_actor::sleep_for(10); @@ -48,7 +48,7 @@ static void receiver(std::vector args) XBT_INFO("Receiving %d flows ...", flow_amount); - simgrid::s4u::MailboxPtr mailbox = simgrid::s4u::Mailbox::byName(std::string("message")); + simgrid::s4u::MailboxPtr mailbox = simgrid::s4u::Mailbox::by_name(std::string("message")); if (flow_amount == 1) { void* res = mailbox->get(); @@ -79,7 +79,7 @@ int main(int argc, char* argv[]) xbt_assert(argc > 1, "\nUsage: %s platform_file [flowCount [datasize]]\n" "\tExample: %s s4uplatform.xml \n", argv[0], argv[0]); - e.loadPlatform(argv[1]); + e.load_platform(argv[1]); /* prepare to launch the actors */ std::vector argSender; @@ -109,8 +109,8 @@ int main(int argc, char* argv[]) } else { // No parameter at all? Then use the default value argSender.push_back("25000"); } - simgrid::s4u::Actor::createActor("sender", simgrid::s4u::Host::by_name("MyHost1"), sender, argSender); - simgrid::s4u::Actor::createActor("receiver", simgrid::s4u::Host::by_name("MyHost2"), receiver, argReceiver); + simgrid::s4u::Actor::create("sender", simgrid::s4u::Host::by_name("MyHost1"), sender, argSender); + simgrid::s4u::Actor::create("receiver", simgrid::s4u::Host::by_name("MyHost2"), receiver, argReceiver); /* And now, launch the simulation */ e.run();