#include <uwmulti-destination.h>
Class used to represents the UwMultiDestination layer of a node.
Definition at line 103 of file uwmulti-destination.h.
◆ Mode
< Switch modes >
Enumerator |
---|
UW_MANUAL_SWITCH | State to switch-mode manually.
|
UW_AUTOMATIC_SWITCH | State to switch-mode automatically.
|
Definition at line 156 of file uwmulti-destination.h.
◆ UwMultiDestination()
UwMultiDestination::UwMultiDestination |
( |
| ) |
|
◆ ~UwMultiDestination()
virtual UwMultiDestination::~UwMultiDestination |
( |
| ) |
|
|
inlinevirtual |
◆ addLayer()
bool UwMultiDestination::addLayer |
( |
IP_range |
range, |
|
|
int |
id |
|
) |
| |
|
virtual |
Add a layer in the layer map if the IP range is valide, i.e., if the range doesn't overlap with an existing one.
- Parameters
-
range | IP range |
id | identifier of the lower layer return false if the range overlaps with an existing one, true otherwise |
Definition at line 144 of file uwmulti-destination.cpp.
◆ checkNotOverlap()
bool UwMultiDestination::checkNotOverlap |
( |
IP_range |
range | ) |
|
|
protectedvirtual |
return true if there is not overlap between the new range and the previous rnage in the list
- Parameters
-
range | that has to be inserted in the list |
- Returns
- true if there is not overlap, false otherwise
Definition at line 201 of file uwmulti-destination.cpp.
◆ command()
int UwMultiDestination::command |
( |
int |
argc, |
|
|
const char *const * |
argv |
|
) |
| |
|
virtual |
TCL command interpreter.
It implements the following OTcl methods:
- Parameters
-
argc | Number of arguments in argv. |
argv | Array of strings which are the command parameters (Note that argv[0] is the name of the object). |
- Returns
- TCL_OK or TCL_ERROR whether the command has been dispatched successfully or not.
Definition at line 81 of file uwmulti-destination.cpp.
◆ getDestinationLayer()
int UwMultiDestination::getDestinationLayer |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
Return the best layer to forward the packet when the system works in AUTOMATIC_MODE.
- Parameters
-
- Returns
- id of the module representing the best layer.
Definition at line 185 of file uwmulti-destination.cpp.
◆ recv()
void UwMultiDestination::recv |
( |
Packet * |
p | ) |
|
|
virtual |
recv method.
It is called when a packet is received from the other layers
- Parameters
-
Packet* | Pointer to the packet that are going to be received |
Definition at line 162 of file uwmulti-destination.cpp.
◆ recvFromUpperLayers()
void UwMultiDestination::recvFromUpperLayers |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
Default lower id to use if dest adress is not found in the considered IP ranges.
Handle a packet coming from upper layers
- Parameters
-
Definition at line 174 of file uwmulti-destination.cpp.
◆ debug_
int UwMultiDestination::debug_ |
|
protected |
◆ default_lower_id
int UwMultiDestination::default_lower_id |
|
protected |
◆ layer_list
◆ layer_not_exist
const int UwMultiDestination::layer_not_exist = -1 |
|
static |
◆ lower_id_active_
int UwMultiDestination::lower_id_active_ |
|
protected |
Id of the current lower layer active.
It is used only in MANUAL MODE.
Definition at line 164 of file uwmulti-destination.h.
◆ min_delay_
double UwMultiDestination::min_delay_ |
|
protected |
◆ switch_mode_
Mode UwMultiDestination::switch_mode_ |
|
protected |
The documentation for this class was generated from the following files: