X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/3e42c9c678d7e69776850a7e168d160f122d24e1..19cd5a52131b50275fa26e0e53c4a8bd333f2937:/src/surf/StorageImpl.hpp diff --git a/src/surf/StorageImpl.hpp b/src/surf/StorageImpl.hpp index 9f410d35cf..b74d624435 100644 --- a/src/surf/StorageImpl.hpp +++ b/src/surf/StorageImpl.hpp @@ -91,7 +91,7 @@ public: /** @brief Public interface */ s4u::Storage piface_; - static StorageImpl* byName(const char* name); + static StorageImpl* byName(std::string name); /** @brief Check if the Storage is used (if an action currently uses its resources) */ bool isUsed() override; @@ -120,7 +120,7 @@ public: /** * @brief Get the content of the current Storage * - * @return A xbt_dict_t with path as keys and size in bytes as values + * @return A map with path as keys and size in bytes as values */ virtual std::map* getContent(); @@ -207,17 +207,22 @@ public: StorageImpl* storage_; FileImpl* file_ = nullptr; }; -} -} -typedef struct s_storage_type { - char* model; - char* content; - char* type_id; - xbt_dict_t properties; +class StorageType { +public: + std::string id; + std::string model; + std::string content; + std::map* properties; std::map* model_properties; sg_size_t size; -} s_storage_type_t; -typedef s_storage_type_t* storage_type_t; + StorageType(std::string id, std::string model, std::string content, std::map* properties, + std::map* model_properties, sg_size_t size) + : id(id), model(model), content(content), properties(properties), model_properties(model_properties), size(size) + { + } +}; +} +} #endif /* STORAGE_INTERFACE_HPP_ */