#include <ip-routing.h>
Inheritance diagram for IPRoutingModule:
Public Member Functions | |
IPRoutingModule () | |
virtual | ~IPRoutingModule () |
virtual void | recv (Packet *p) |
virtual int | command (int argc, const char *const *argv) |
virtual nsaddr_t | GetNextHop (Packet *p) |
virtual nsaddr_t | GetNextHop (nsaddr_t dst) |
virtual void | clearRoutes () |
virtual void | addRoute (nsaddr_t dst, nsaddr_t mask, nsaddr_t next) |
Protected Attributes | |
nsaddr_t | destination [IP_ROUTING_MAX_ROUTES] |
nsaddr_t | subnetmask [IP_ROUTING_MAX_ROUTES] |
nsaddr_t | nexthop [IP_ROUTING_MAX_ROUTES] |
int | nroutes |
This class implements tcl class Module/IP/Routing and is expected to be installed above one or more Module/IP/Interface classes.
Definition at line 54 of file ip-routing.h.
void IPRoutingModule::recv | ( | Packet * | p | ) | [virtual] |
Abstract method which has to be filled with the ad-hoc operations that the module has to do to the packet received
p | pointer to the packet will be received |
Reimplemented from IPModule.
Definition at line 152 of file ip-routing.cc.
References DOWN, Module::drop(), GetNextHop(), Module::sendDown(), Module::sendUp(), and UP.
Here is the call graph for this function:
int IPRoutingModule::command | ( | int | argc, | |
const char *const * | argv | |||
) | [virtual] |
TCL command interpreter. It implements the following OTcl methods:
Moreover it inherits all the OTcl method of PlugIn
argc | number of arguments in argv | |
argv | array of strings which are the comand parameters (Note that argv[0] is the name of the object) |
Reimplemented from IPModule.
Definition at line 87 of file ip-routing.cc.
References addRoute(), clearRoutes(), Module::command(), destination, nexthop, nroutes, IPModule::str2addr(), and subnetmask.
Here is the call graph for this function: