LinkChannelModule Class Reference

#include <link_channel.h>

Inheritance diagram for LinkChannelModule:

Inheritance graph
[legend]
Collaboration diagram for LinkChannelModule:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 LinkChannelModule ()
virtual ~LinkChannelModule ()
virtual int command (int argc, const char *const *argv)
virtual void recv (Packet *p, ChSAP *cs)
virtual void recv (Packet *p, Handler *h)

Protected Attributes

NsObject * linkhead_
ChSAPsrcsap
ChSAPdstsap

Friends

class DropInterface

Detailed Description

A wrapper for standard ns Link

Definition at line 57 of file link_channel.h.


Member Function Documentation

int LinkChannelModule::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 comand parameters (Note that argv[0] is the name of the object)
Returns:
TCL_OK or TCL_ERROR whether the command has been dispatched succesfully or no
See also:
ChannelModule, Module, PlugIn

Reimplemented from ChannelModule.

Definition at line 57 of file link_channel.cc.

References ChannelModule::command(), dstsap, linkhead_, and srcsap.

Here is the call graph for this function:

void LinkChannelModule::recv ( Packet *  p,
ChSAP cs 
) [virtual]

This method is invoked when a packet is passed by an upper ChSap to this module

Parameters:
p pointer to the packet packet
c pointer to the ChSap which passed the packet

Implements ChannelModule.

Definition at line 115 of file link_channel.cc.

References linkhead_, and srcsap.

void LinkChannelModule::recv ( Packet *  p,
Handler *  h 
) [virtual]

This method is used by NsObjects wrapped inside the LinkChannel class to pass packets to it. It should NOT be used by ChSAPs

Parameters:
p packet
h handler

Reimplemented from ChannelModule.

Definition at line 137 of file link_channel.cc.

References Module::drop(), dstsap, LINKCH_DROP_REASON_ERROR, ChSAP::sendUp(), and srcsap.

Here is the call graph for this function:


The documentation for this class was generated from the following files:
Generated on Wed Nov 26 15:48:54 2008 for NS-MIRACLE library by  doxygen 1.5.2