Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Inventive hack to get flex raising exceptions on parse error
[simgrid.git] / src / surf / StorageImpl.hpp
index da13a3c..bd885d0 100644 (file)
@@ -8,7 +8,6 @@
 #include "simgrid/kernel/resource/Resource.hpp"
 #include "simgrid/s4u/Io.hpp"
 #include "simgrid/s4u/Storage.hpp"
-#include "src/kernel/resource/profile/trace_mgr.hpp"
 #include "src/surf/PropertyHolder.hpp"
 #include "surf_interface.hpp"
 
@@ -61,6 +60,8 @@ public:
  * @details A Storage represent a storage unit (e.g.: hard drive, usb key)
  */
 class StorageImpl : public Resource, public surf::PropertyHolder {
+  s4u::Storage piface_;
+
 public:
   /** @brief Storage constructor */
   StorageImpl(Model* model, const std::string& name, kernel::lmm::System* maxmin_system, double bread, double bwrite,
@@ -70,9 +71,7 @@ public:
 
   ~StorageImpl() override;
 
-  /** @brief Public interface */
-  s4u::Storage piface_;
-
+  s4u::Storage* get_iface() { return &piface_; }
   /** @brief Check if the Storage is used (if an action currently uses its resources) */
   bool is_used() override;
 
@@ -82,7 +81,7 @@ public:
   void turn_off() override;
 
   void destroy(); // Must be called instead of the destructor
-  virtual Action* io_start(sg_size_t size, s4u::Io::OpType type) = 0;
+  virtual StorageAction* io_start(sg_size_t size, s4u::Io::OpType type) = 0;
   /**
    * @brief Read a file
    *