Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | Related Pages

NicEntryDebug Class Reference
[channelControl - channel and connection related classes]

NicEntry is used by ChannelControl to store the necessary information for each nic. More...

#include <NicEntryDebug.h>

Inherits NicEntry.

Inheritance diagram for NicEntryDebug:

Inheritance graph
[legend]
Collaboration diagram for NicEntryDebug:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 NicEntryDebug (bool debug)
 Constrcutor, initializes all members.
virtual ~NicEntryDebug ()
 Destructor -- needs to be there...
virtual void connectTo (NicEntry *)
 Connect two nics.
virtual void disconnectFrom (NicEntry *)
 Disconnect two nics.

Protected Member Functions

cGate * requestInGate (void)
 Returns a free in gate of the nic.
cGate * requestOutGate (void)
 Returns a free out gate of the nic.

Protected Attributes

int inCnt
 Number of in gates allocated for the nic so far.
int outCnt
 Number of out gates allocated for the nic so far.
std::vector< cGate * > freeInGates
 In Gates that were once used but are not connected now.
std::vector< cGate * > freeOutGates
 Out Gates that were once used but are not connected now.

Detailed Description

NicEntry is used by ChannelControl to store the necessary information for each nic.

Author:
Daniel Willkomm
See also:
ChannelControl, NicEntry


Constructor & Destructor Documentation

NicEntryDebug::NicEntryDebug bool  debug  )  [inline]
 

Constrcutor, initializes all members.

Todo:
initialize position!


Member Function Documentation

void NicEntryDebug::connectTo NicEntry other  )  [virtual]
 

Connect two nics.

Establish unidirectional connection with other nic

Parameters:
other reference to remote nic (other NicEntry)
This function acquires an in gate at the remote nic and an out gate at this nic, connects the two and updates the freeInGate, freeOutGate and outConns data sets.

It handles compound modules correctly, provided that the physical module is called "phy" or "snrEval" respectively in the .ned files.

Implements NicEntry.

void NicEntryDebug::disconnectFrom NicEntry other  )  [virtual]
 

Disconnect two nics.

Release unidirectional connection with other nic

Parameters:
other reference to remote nic (other NicEntry)

Implements NicEntry.

cGate * NicEntryDebug::requestInGate void   )  [protected]
 

Returns a free in gate of the nic.

This checks the list of free in gates, if one is available it is returned. Otherwise, a new in gate is added to the nic. This function handles the interaction with snrEval / phy and nic corectly, provided that the phy name is "snrEval or "phy" respectively in the .ned files.

cGate * NicEntryDebug::requestOutGate void   )  [protected]
 

Returns a free out gate of the nic.

returns a free out gate. If none is available it is created. See NicEntry::requestInGate for a detailed description


The documentation for this class was generated from the following files:
Generated on Fri Jan 12 08:30:10 2007 for Mobility Framework by  doxygen 1.4.4