Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[surf] Move some code in a simgrid::surf namespace
[simgrid.git] / include / simgrid / forward.h
index 2f6279c..1875ce9 100644 (file)
@@ -8,25 +8,35 @@
 #define SG_PLATF_TYPES_H
 
 #include <xbt.h>
-#include <simgrid/host.h>
 
 #ifdef __cplusplus
 
+namespace simgrid {
+namespace surf {
+
 class Cpu;
 class RoutingEdge;
+class As;
 
-#else
+}
+}
 
-typedef struct Cpu Cpu;
-typedef struct RoutingEdge RoutingEdge;
+typedef simgrid::surf::Cpu surf_Cpu;
+typedef simgrid::surf::RoutingEdge surf_RoutingEdge;
+typedef simgrid::surf::As surf_As;
 
-#endif
+#else
 
-typedef Cpu *surf_cpu_t;
-typedef RoutingEdge *routing_edge_t;
-typedef RoutingEdge *sg_routing_edge_t;
+typedef struct surf_Cpu surf_Cpu;
+typedef struct surf_RoutingEdge surf_RoutingEdge;
+typedef struct surf_As surf_As;
 
+#endif
 
+typedef surf_Cpu *surf_cpu_t;
+typedef surf_RoutingEdge *routing_edge_t;
+typedef surf_RoutingEdge *sg_routing_edge_t;
+typedef surf_As *AS_t;
 
 // Types which are in fact dictelmt: