Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Update copyright lines.
[simgrid.git] / src / kernel / resource / profile / Profile.hpp
index 305808a..c2c5b8e 100644 (file)
@@ -1,28 +1,23 @@
-/* Copyright (c) 2004-2019. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2004-2021. The SimGrid Team. All rights reserved.          */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
 
-#ifndef PROFILE_HPP
-#define PROFILE_HPP
+#ifndef SIMGRID_KERNEL_PROFILE_HPP
+#define SIMGRID_KERNEL_PROFILE_HPP
 
+#include "simgrid/forward.h"
 #include "src/kernel/resource/profile/DatedValue.hpp"
 #include "src/kernel/resource/profile/FutureEvtSet.hpp"
-#include <vector>
+#include "src/kernel/resource/profile/StochasticDatedValue.hpp"
+
 #include <queue>
+#include <vector>
 
 namespace simgrid {
 namespace kernel {
 namespace profile {
-       
-class Event {
-public:
-  Profile* profile;
-  unsigned int idx;
-  resource::Resource* resource;
-  bool free_me;
-};
-       
+
 /** @brief A profile is a set of timed values, encoding the value that a variable takes at what time
  *
  * It is useful to model dynamic platforms, where an external load that makes the resource availability change over
@@ -41,13 +36,20 @@ public:
   static Profile* from_string(const std::string& name, const std::string& input, double periodicity);
   // private:
   std::vector<DatedValue> event_list;
+  std::vector<StochasticDatedValue> stochastic_event_list;
 
 private:
-  FutureEvtSet* fes_ = nullptr;
+  FutureEvtSet* fes_  = nullptr;
+  bool stochastic     = false;
+  bool stochasticloop = false;
+  DatedValue futureDV;
 };
 
 } // namespace profile
 } // namespace kernel
 } // namespace simgrid
 
-#endif
\ No newline at end of file
+/** Module finalizer: frees all profiles */
+XBT_PUBLIC void tmgr_finalize();
+
+#endif