X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/b455d03d623a399cab4a08171a5e5b3ed3b1292b..b3a19f2cc0136088a395b37f4a9cfd9578815f06:/src/kernel/resource/WifiLinkImpl.hpp?ds=sidebyside diff --git a/src/kernel/resource/WifiLinkImpl.hpp b/src/kernel/resource/WifiLinkImpl.hpp index 5f5fec09a1..ad08b6c3ed 100644 --- a/src/kernel/resource/WifiLinkImpl.hpp +++ b/src/kernel/resource/WifiLinkImpl.hpp @@ -6,10 +6,8 @@ #ifndef SURF_NETWORK_WIFI_HPP_ #define SURF_NETWORK_WIFI_HPP_ -#include - #include "src/surf/network_cm02.hpp" -#include "xbt/string.hpp" +#include "xbt/base.h" /*********** * Classes * @@ -21,7 +19,7 @@ class XBT_PRIVATE WifiLinkAction; class WifiLinkImpl : public StandardLinkImpl { /** @brief Hold every rates association between host and links (host name, rates id) */ - std::map host_rates_; + std::map> host_rates_; /** @brief A link can have several bandwidths attached to it (mostly use by wifi model) */ std::vector bandwidths_; @@ -53,15 +51,15 @@ public: void apply_event(kernel::profile::Event*, double) override { THROW_UNIMPLEMENTED; } void set_bandwidth(double) override { THROW_UNIMPLEMENTED; } void set_latency(double) override; - double get_max_ratio(); bool toggle_callback(); static void update_bw_comm_start(const kernel::activity::CommImpl&); - static void update_bw_comm_end(simgrid::kernel::resource::NetworkAction& action, simgrid::kernel::resource::Action::State state); + static void update_bw_comm_end(const simgrid::kernel::resource::NetworkAction& action, + simgrid::kernel::resource::Action::State state); void inc_active_flux(); void dec_active_flux(); - static double wifi_link_dynamic_sharing(WifiLinkImpl* link, double capacity, int n); - double get_max_ratio(int); + static double wifi_link_dynamic_sharing(const WifiLinkImpl& link, double capacity, int n); + double get_max_ratio() const; size_t get_host_count() const; };