X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/2d70b641ae218aba41b9cd70914419abcfa63b94..71cecd7bcda32076656fc615784a1146c910b6b5:/src/surf/network_cm02.hpp diff --git a/src/surf/network_cm02.hpp b/src/surf/network_cm02.hpp index cf97be463f..7970a18339 100644 --- a/src/surf/network_cm02.hpp +++ b/src/surf/network_cm02.hpp @@ -38,15 +38,15 @@ namespace simgrid { class NetworkCm02Model : public NetworkModel { public: - NetworkCm02Model(); - ~NetworkCm02Model() { } + explicit NetworkCm02Model(); + explicit NetworkCm02Model(void (*solve_fun)(lmm_system_t self)); + virtual ~NetworkCm02Model(); Link* createLink(const char *name, double bandwidth, double latency, e_surf_link_sharing_policy_t policy, xbt_dict_t properties) override; void updateActionsStateLazy(double now, double delta) override; void updateActionsStateFull(double now, double delta) override; - Action *communicate(NetCard *src, NetCard *dst, double size, double rate) override; - bool next_occuring_event_isIdempotent() override {return true;} - virtual void gapAppend(double /*size*/, const Link* /*link*/, NetworkAction * /*action*/) {}; + Action *communicate(kernel::routing::NetCard *src, kernel::routing::NetCard *dst, double size, double rate) override; + virtual void gapAppend(double size, const Link* link, NetworkAction* action); protected: bool haveGap_ = false; }; @@ -60,11 +60,11 @@ namespace simgrid { NetworkCm02Link(NetworkCm02Model *model, const char *name, xbt_dict_t props, double bandwidth, double latency, e_surf_link_sharing_policy_t policy, lmm_system_t system); - + ~NetworkCm02Link() override; void apply_event(tmgr_trace_iterator_t event, double value) override; void updateBandwidth(double value) override; void updateLatency(double value) override; - virtual void gapAppend(double /*size*/, const Link* /*link*/, NetworkAction * /*action*/) {}; + virtual void gapAppend(double size, const Link* link, NetworkAction* action); }; @@ -72,13 +72,13 @@ namespace simgrid { * Action * **********/ class NetworkCm02Action : public NetworkAction { - friend Action *NetworkCm02Model::communicate(NetCard *src, NetCard *dst, double size, double rate); + friend Action *NetworkCm02Model::communicate(kernel::routing::NetCard *src, kernel::routing::NetCard *dst, double size, double rate); friend NetworkSmpiModel; - public: NetworkCm02Action(Model *model, double cost, bool failed) - : NetworkAction(model, cost, failed) {}; - void updateRemainingLazy(double now); + : NetworkAction(model, cost, failed) {}; + ~NetworkCm02Action() override; + void updateRemainingLazy(double now) override; protected: double senderGap_; };