-// ========== Simix layer =============
-smx_host_priv_t sg_host_simix(sg_host_t host){
- return (smx_host_priv_t) host->extension(SIMIX_HOST_LEVEL);
-}
-void sg_host_simix_set(sg_host_t host, smx_host_priv_t smx_host) {
- host->extension_set(SIMIX_HOST_LEVEL, smx_host);
-}
-void sg_host_simix_destroy(sg_host_t host) {
- host->extension_set(SIMIX_HOST_LEVEL, nullptr);
-}
-
-// ========== SURF CPU ============
-surf_cpu_t sg_host_surfcpu(sg_host_t host) {
- return host->extension<simgrid::surf::Cpu>();
-}
-void sg_host_surfcpu_set(sg_host_t host, surf_cpu_t cpu) {
- host->extension_set(simgrid::surf::Cpu::EXTENSION_ID, cpu); // FIXME: use the typesafe version
-}
-void sg_host_surfcpu_destroy(sg_host_t host) {
- host->extension_set<simgrid::surf::Cpu>(nullptr);
-}
-// ========== RoutingEdge ============
-surf_RoutingEdge *sg_host_edge(sg_host_t host) {
- return (surf_RoutingEdge*) host->extension(ROUTING_HOST_LEVEL);
-}
-void sg_host_edge_set(sg_host_t host, surf_RoutingEdge *edge) {
- host->extension_set(ROUTING_HOST_LEVEL, edge);
-}
-void sg_host_edge_destroy(sg_host_t host, int do_callback) {
- host->extension_set(ROUTING_HOST_LEVEL, nullptr, do_callback);
+xbt_dynar_t sg_host_get_attached_storage_list(sg_host_t host){
+ std::vector<const char*>* storage_vector = new std::vector<const char*>();
+ xbt_dynar_t storage_dynar = xbt_dynar_new(sizeof(const char*), nullptr);
+ host->attachedStorages(storage_vector);
+ for (auto name : *storage_vector)
+ xbt_dynar_push(storage_dynar, &name);
+ delete storage_vector;
+ return storage_dynar;