10 neighbor(const char* hostname);
13 // returns name, ctrl or data mbox
14 const char* get_name() const { return host->get_name(); }
15 const char* get_ctrl_mbox() const { return host->get_ctrl_mbox(); }
16 const char* get_data_mbox() const { return host->get_data_mbox(); }
18 // Getter and setter for load
19 double get_load() const { return load; }
20 void set_load(double amount) { load = amount; }
22 // Getter and setter for debt
23 double get_debt() const { return debt; }
24 void set_debt(double amount) { debt = amount; }
26 // Getter and setter for to_send
27 double get_to_send() const { return to_send; }
28 void set_to_send(double amount) { to_send = amount; }
29 void add_to_send(double amount) { to_send += amount; }
31 // Prints its name and load on given category, with given
32 // priority. If verbose is true, prints debt and to_send too.
33 void print(bool verbose = false,
34 e_xbt_log_priority_t logp = xbt_log_priority_info,
35 xbt_log_category_t cat = _XBT_LOGV(default)) const;
38 const hostdata* host; // pointer to this neighbor's hostdata
40 double load; // the load information we know for it
41 double debt; // the load we had to send to it, but
42 // that we have not currently sent
43 // (in bookkeeping mode)
45 double to_send; // the load we have to send to it