1 /* Copyright (c) 2008, 2009, 2010. The SimGrid Team.
2 * All rights reserved. */
4 /* This program is free software; you can redistribute it and/or modify it
5 * under the terms of the license (GNU LGPL) which comes with this package. */
9 #include "simdag/simdag.h"
10 #include "surf/surf_private.h"
12 extern routing_global_t global_routing;
14 int main(int argc, char **argv)
16 /* initialisation of SD */
18 xbt_dict_t eltms = xbt_dict_new();
20 xbt_dict_cursor_t cursor = NULL;
23 /* creation of the environment */
24 SD_create_environment(argv[1]);
26 eltms = global_routing->where_network_elements;
27 size = xbt_dict_size(eltms);
29 printf("Workstation number: %d, link number: %d, elmts number: %d\n",
30 SD_workstation_get_number(), SD_link_get_number(), size);
32 xbt_dict_foreach(eltms, cursor, key, data) {
33 printf(" - Seen: \"%s\" is type : %d\n", key,
34 (int) global_routing->get_network_element_type(key));
36 //printf("%s is router : %d\n",name1,global_routing->is_router(name1));
37 xbt_dict_free(&eltms);