Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
another bunch of include cuts. The last one for today
[simgrid.git] / include / simgrid / s4u / VirtualMachine.hpp
index 968090b..6dfb999 100644 (file)
@@ -6,12 +6,20 @@
 #ifndef SIMGRID_S4U_VM_HPP
 #define SIMGRID_S4U_VM_HPP
 
-#include <simgrid/s4u/forward.hpp>
-#include <simgrid/s4u/host.hpp>
-#include <xbt/base.h>
+#include "simgrid/datatypes.h"
+#include "simgrid/s4u/forward.hpp"
+#include "simgrid/s4u/host.hpp"
 
-namespace simgrid {
+typedef enum {
+  SURF_VM_STATE_CREATED, /**< created, but not yet started */
+  SURF_VM_STATE_RUNNING,
+  SURF_VM_STATE_SUSPENDED, /**< Suspend/resume does not involve disk I/O, so we assume there is no transition states. */
+} e_surf_vm_state_t;
 
+namespace simgrid {
+namespace vm {
+class VirtualMachineImpl;
+};
 namespace s4u {
 
 /** @ingroup s4u_api
@@ -36,8 +44,15 @@ private:
   virtual ~VirtualMachine();
 
 public:
-  void parameters(vm_params_t params) override;
-  void setParameters(vm_params_t params) override;
+  bool isMigrating();
+
+  void parameters(vm_params_t params);
+  void setParameters(vm_params_t params);
+  double getRamsize();
+  simgrid::s4u::Host* pm();
+
+  /* FIXME: protect me */
+  simgrid::vm::VirtualMachineImpl* pimpl_vm_ = nullptr;
 };
 }
 } // namespace simgrid::s4u