#include <permalink_communication_model.h>


Public Member Functions | |
construction / destruction / init | |
| PermalinkCommunicationModel () | |
| virtual | ~PermalinkCommunicationModel () |
| virtual void | init (void) throw () |
edges | |
| virtual void | add_edge (std::string, std::string) throw () |
CommunicationModel interface | |
| virtual bool | can_communicate_bidi (const Node &, const Node &) const throw () |
| virtual bool | can_communicate_uni (const Node &, const Node &) const throw () |
| virtual bool | exists_communication_upper_bound (void) const throw () |
| returns whether communication_upper_bound() returns a useful value | |
| virtual double | communication_upper_bound (void) const throw () |
| virtual bool | is_status_available_on_construction (void) const throw () |
| virtual bool | in_domain (const Node &, const Node &) const throw () |
| Returns true if this instance is able to anser the can_communicate_uni() and can_communicate_bidi() questions. | |
Unidirectional edges can be added manually by using add_edge(). Alternatively, see PermalinkCommunicationModelFactory on how to configure the static links by using Tag entries in the SimulationEnvironment.
| shawn::PermalinkCommunicationModel::PermalinkCommunicationModel | ( | ) |
| virtual shawn::PermalinkCommunicationModel::~PermalinkCommunicationModel | ( | ) | [virtual] |
| virtual void shawn::PermalinkCommunicationModel::init | ( | void | ) | throw () [virtual] |
called after world is setup and before first node is created. used by World
Reimplemented from shawn::CommunicationModel.
| virtual void shawn::PermalinkCommunicationModel::add_edge | ( | std::string | , | |
| std::string | ||||
| ) | throw () [virtual] |
| virtual bool shawn::PermalinkCommunicationModel::can_communicate_bidi | ( | const Node & | , | |
| const Node & | ||||
| ) | const throw () [virtual] |
true iff can_communicate_uni(u,v) and can_communicate_uni(v,u), therefore, whether the two nodes may exchange messages. Implements shawn::CommunicationModel.
| virtual bool shawn::PermalinkCommunicationModel::can_communicate_uni | ( | const Node & | , | |
| const Node & | ||||
| ) | const throw () [virtual] |
true if the first passed node can send messages to the second. Implements shawn::CommunicationModel.
| virtual bool shawn::PermalinkCommunicationModel::exists_communication_upper_bound | ( | void | ) | const throw () [virtual] |
returns whether communication_upper_bound() returns a useful value
Implements shawn::CommunicationModel.
| virtual double shawn::PermalinkCommunicationModel::communication_upper_bound | ( | void | ) | const throw () [virtual] |
if exists_communication_upper_bound(), nodes whose euclidean distance exceeds communication_upper_bound() can never communicate in any direction.
Providing such a value is useful because EdgeModel instances might use the information for geographical caching.
Implements shawn::CommunicationModel.
| virtual bool shawn::PermalinkCommunicationModel::is_status_available_on_construction | ( | void | ) | const throw () [virtual] |
Implements shawn::CommunicationModel.
| virtual bool shawn::PermalinkCommunicationModel::in_domain | ( | const Node & | , | |
| const Node & | ||||
| ) | const throw () [virtual] |
Returns true if this instance is able to anser the can_communicate_uni() and can_communicate_bidi() questions.
The default implementation returns true. Override this method to implement communication model specific intelligence. This is mainly used in conjunction with MultipleCommunicationModel to combine several CommunicationModels
Reimplemented from shawn::CommunicationModel.
1.5.6