Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add battery plugin and fix DAG doc
[simgrid.git] / include / simgrid / plugins / battery.hpp
diff --git a/include/simgrid/plugins/battery.hpp b/include/simgrid/plugins/battery.hpp
new file mode 100644 (file)
index 0000000..3899ff0
--- /dev/null
@@ -0,0 +1,27 @@
+#ifndef SIMGRID_PLUGINS_BATTERY_H_
+#define SIMGRID_PLUGINS_BATTERY_H_
+
+#include <simgrid/config.h>
+#include <simgrid/forward.h>
+#include <xbt/base.h>
+
+SG_BEGIN_DECL
+
+XBT_PUBLIC void sg_battery_plugin_init();
+
+XBT_PUBLIC void sg_battery_set_state(const_sg_host_t host, bool state);
+XBT_PUBLIC void sg_battery_set_power(const_sg_host_t host, double power);
+
+XBT_PUBLIC bool sg_battery_is_active(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_power(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_state_of_charge(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_state_of_charge_min(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_state_of_charge_max(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_state_of_health(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_capacity(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_cumulative_cost(const_sg_host_t host);
+XBT_PUBLIC double sg_battery_get_next_event_date(const_sg_host_t host);
+
+SG_END_DECL
+
+#endif
\ No newline at end of file