1 /* Copyright (c) 2008-2015. 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 "simgrid/simdag.h"
10 #include "surf/surf_private.h"
12 extern routing_platf_t routing_platf;
14 int main(int argc, char **argv)
16 /* SD initialization */
18 xbt_lib_cursor_t cursor = NULL;
28 /* creation of the environment */
29 SD_create_environment(argv[1]);
31 size = xbt_lib_length(host_lib) + xbt_lib_length(as_router_lib);
33 printf("Workstation number: %d, link number: %d, elmts number: %d\n",
34 SD_workstation_get_number(), SD_link_get_number(), size);
36 xbt_lib_foreach(host_lib, cursor, key, data) {
37 printf(" - Seen: \"%s\" is type : %d\n", key,
38 (int) routing_get_network_element_type(key));
41 xbt_lib_foreach(as_router_lib, cursor, key, data) {
42 printf(" - Seen: \"%s\" is type : %d\n", key,
43 (int) routing_get_network_element_type(key));