Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
BUGFIX bindinig always with port 80 cause more than two incoming flows on the same...
[simgrid.git] / src / surf / gtnets / gtnets_interface.h
1 /*      $Id$     */
2 /* Copyright (c) 2007 Kayo Fujiwara. All rights reserved.                  */
3
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. */
6
7 // Interface for GTNetS.
8 #ifndef _GTNETS_INTERFACE_H
9 #define _GTNETS_INTERFACE_H
10
11 #ifdef __cplusplus
12 extern "C" {
13 #endif
14   
15   int gtnets_initialize();
16   int gtnets_add_link(int id, double bandwidth, double latency);
17   int gtnets_add_route(int src, int dst, int* links, int nlink);
18   int gtnets_add_router(int id);
19   int gtnets_add_onehop_route(int src, int dst, int link);
20   int gtnets_create_flow(int src, int dst, long datasize, void* metadata);
21   double gtnets_get_time_to_next_flow_completion();
22   int gtnets_run_until_next_flow_completion(void*** metadata, int* number_of_flows);
23   double gtnets_get_flow_rx(void *metadata);
24
25   int gtnets_run(double delta);
26   int gtnets_finalize();
27
28 #ifdef __cplusplus
29 }
30 #endif
31
32 #endif
33
34