-/* Copyright (c) 2013-2016. The SimGrid Team.
- * All rights reserved. */
+/* Copyright (c) 2013-2017. 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. */
#include <vector>
-#include "xbt/dict.h"
#include "simgrid/host.h"
-#include <xbt/Extendable.hpp>
-#include <simgrid/s4u/host.hpp>
+#include "simgrid/s4u/Host.hpp"
+#include "xbt/Extendable.hpp"
+#include "xbt/dict.h"
#include "src/kernel/routing/NetPoint.hpp"
#include "src/simix/smx_host_private.h"
void sg_host_dump(sg_host_t host)
{
xbt_dict_t props;
- xbt_dict_cursor_t cursor=nullptr;
- char *key,*data;
XBT_INFO("Displaying host %s", host->cname());
XBT_INFO(" - speed: %.0f", host->speed());
XBT_INFO(" - available speed: %.2f", sg_host_get_available_speed(host));
props = host->properties();
- if (!xbt_dict_is_empty(props)){
+ if (not xbt_dict_is_empty(props)) {
XBT_INFO(" - properties:");
+ xbt_dict_cursor_t cursor = nullptr;
+ char* key;
+ char* data;
xbt_dict_foreach(props,cursor,key,data) {
XBT_INFO(" %s->%s",key,data);