Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
woops
[simgrid.git] / src / instr / jedule / jedule_platform.cpp
index cc3037e..c0060d5 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2017. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2010-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. */
@@ -64,15 +64,14 @@ void Container::addResources(std::vector<sg_host_t> hosts)
 void Container::createHierarchy(sg_netzone_t from_as)
 {
 
-  if (from_as->getChildren()->empty()) {
+  if (from_as->get_children()->empty()) {
     // I am no AS
     // add hosts to jedule platform
-    std::vector<sg_host_t> table;
-    from_as->getHosts(&table);
+    std::vector<sg_host_t> table = from_as->get_all_hosts();
     this->addResources(table);
   } else {
-    for (auto const& nz : *from_as->getChildren()) {
-      jed_container_t child_container = new simgrid::jedule::Container(std::string(nz->getCname()));
+    for (auto const& nz : *from_as->get_children()) {
+      jed_container_t child_container = new simgrid::jedule::Container(std::string(nz->get_cname()));
       this->addChild(child_container);
       child_container->createHierarchy(nz);
     }